diff --git a/installer/dev/main.cpp b/installer/dev/main.cpp index 8fe2f4b73f..ce62f6bd11 100644 --- a/installer/dev/main.cpp +++ b/installer/dev/main.cpp @@ -82,7 +82,7 @@ int wmain(int argc, wchar_t *argv[]) else if ((arg == L"-?") || (arg == L"--help")) { DisplayHelp(); - return 1; + return 0; } else if ((arg == L"--info")) { diff --git a/installer/test/InstallerFunctionalTests/constants.h b/installer/test/InstallerFunctionalTests/constants.h index 3659cae470..58596a3bfe 100644 --- a/installer/test/InstallerFunctionalTests/constants.h +++ b/installer/test/InstallerFunctionalTests/constants.h @@ -19,10 +19,9 @@ #define CONFIGURATION L"Release" #endif -#define BUILDOUTPUT_DIR L"BuildOutput" #define INSTALLER_DIR L"WindowsAppRuntimeInstall" -#define INSTALLER_FILENAME L"WindowsAppRuntimeInstall-" ARCH L"exe" -#define INSTALLER_EXE_PATH BUILDOUTPUT_DIR L"\\" CONFIGURATION L"\\" ARCH L"\\" INSTALLER_DIR L"\\" INSTALLER_FILENAME +#define INSTALLER_FILENAME L"WindowsAppRuntimeInstall-" ARCH L".exe" +#define INSTALLER_EXE_PATH INSTALLER_DIR L"\\" INSTALLER_FILENAME namespace WindowsAppRuntimeInstallerTests { diff --git a/installer/test/InstallerFunctionalTests/helpers.cpp b/installer/test/InstallerFunctionalTests/helpers.cpp index 5c29a9632f..773759d367 100644 --- a/installer/test/InstallerFunctionalTests/helpers.cpp +++ b/installer/test/InstallerFunctionalTests/helpers.cpp @@ -118,6 +118,10 @@ namespace WindowsAppRuntimeInstallerTests std::filesystem::path GetModulePath(HMODULE hmodule) { + if (hmodule == NULL) + { + hmodule = GetModuleHandle(L"InstallerFunctionalTests.dll"); + } auto path{ GetModuleFileName(hmodule) }; return path.remove_filename(); } @@ -134,7 +138,7 @@ namespace WindowsAppRuntimeInstallerTests // TAEF runs as a package under the installer, so we have to go way up the parent root in order to // get to the common project root and then get to the build output. - return path.parent_path().parent_path().parent_path().parent_path().parent_path().parent_path().parent_path(); + return path.parent_path().parent_path(); } std::filesystem::path GetInstallerPath()