diff options
| author | Sean Hall <r.sean.hall@gmail.com> | 2019-02-15 19:08:58 -0600 |
|---|---|---|
| committer | Sean Hall <r.sean.hall@gmail.com> | 2019-02-15 19:20:29 -0600 |
| commit | 1144983d580524f1e22e0ddd2416955cda8063d2 (patch) | |
| tree | 896e9cb9832805ce9a7f2c33467bda8c37ff932e /src/test | |
| parent | 391057093e45db2d4b2450bd236b9e1fc4cfd53c (diff) | |
| download | wix-1144983d580524f1e22e0ddd2416955cda8063d2.tar.gz wix-1144983d580524f1e22e0ddd2416955cda8063d2.tar.bz2 wix-1144983d580524f1e22e0ddd2416955cda8063d2.zip | |
WIXFEAT:3815 - Update mbahost test for BootstrapperApplicationFactoryAttribute.
Diffstat (limited to 'src/test')
5 files changed, 37 insertions, 6 deletions
diff --git a/src/test/WixToolsetTest.MbaHost/TestManagedBootstrapperApplication.h b/src/test/WixToolsetTest.MbaHost/TestManagedBootstrapperApplication.h index 1dfd0d4d..d74d90c5 100644 --- a/src/test/WixToolsetTest.MbaHost/TestManagedBootstrapperApplication.h +++ b/src/test/WixToolsetTest.MbaHost/TestManagedBootstrapperApplication.h | |||
| @@ -13,6 +13,12 @@ namespace Native | |||
| 13 | public ref class TestManagedBootstrapperApplication : BootstrapperApplication | 13 | public ref class TestManagedBootstrapperApplication : BootstrapperApplication |
| 14 | { | 14 | { |
| 15 | public: | 15 | public: |
| 16 | TestManagedBootstrapperApplication(WixToolset::BootstrapperCore::Engine^ engine, WixToolset::BootstrapperCore::Command command) | ||
| 17 | : BootstrapperApplication(engine, command) | ||
| 18 | { | ||
| 19 | |||
| 20 | } | ||
| 21 | |||
| 16 | virtual void Run() override | 22 | virtual void Run() override |
| 17 | { | 23 | { |
| 18 | } | 24 | } |
| @@ -23,8 +29,6 @@ namespace Native | |||
| 23 | this->Engine->Log(LogLevel::Standard, message); | 29 | this->Engine->Log(LogLevel::Standard, message); |
| 24 | } | 30 | } |
| 25 | }; | 31 | }; |
| 26 | |||
| 27 | [assembly:BootstrapperApplication(TestManagedBootstrapperApplication::typeid)]; | ||
| 28 | } | 32 | } |
| 29 | } | 33 | } |
| 30 | } \ No newline at end of file | 34 | } \ No newline at end of file |
diff --git a/src/test/WixToolsetTest.MbaHost/TestManagedBootstrapperApplicationFactory.h b/src/test/WixToolsetTest.MbaHost/TestManagedBootstrapperApplicationFactory.h new file mode 100644 index 00000000..9d44075b --- /dev/null +++ b/src/test/WixToolsetTest.MbaHost/TestManagedBootstrapperApplicationFactory.h | |||
| @@ -0,0 +1,25 @@ | |||
| 1 | #pragma once | ||
| 2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | ||
| 3 | |||
| 4 | namespace WixToolsetTest | ||
| 5 | { | ||
| 6 | namespace MbaHost | ||
| 7 | { | ||
| 8 | namespace Native | ||
| 9 | { | ||
| 10 | using namespace System; | ||
| 11 | using namespace WixToolset::BootstrapperCore; | ||
| 12 | |||
| 13 | public ref class TestManagedBootstrapperApplicationFactory : public BaseBootstrapperApplicationFactory | ||
| 14 | { | ||
| 15 | protected: | ||
| 16 | virtual IBootstrapperApplication^ Create(Engine^ engine, Command% command) override | ||
| 17 | { | ||
| 18 | return gcnew TestManagedBootstrapperApplication(engine, command); | ||
| 19 | } | ||
| 20 | }; | ||
| 21 | |||
| 22 | [assembly:BootstrapperApplicationFactory(TestManagedBootstrapperApplicationFactory::typeid)]; | ||
| 23 | } | ||
| 24 | } | ||
| 25 | } \ No newline at end of file | ||
diff --git a/src/test/WixToolsetTest.MbaHost/WixToolsetTest.MbaHost.vcxproj b/src/test/WixToolsetTest.MbaHost/WixToolsetTest.MbaHost.vcxproj index 557aaff0..a95a1606 100644 --- a/src/test/WixToolsetTest.MbaHost/WixToolsetTest.MbaHost.vcxproj +++ b/src/test/WixToolsetTest.MbaHost/WixToolsetTest.MbaHost.vcxproj | |||
| @@ -2,7 +2,7 @@ | |||
| 2 | <!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. --> | 2 | <!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. --> |
| 3 | <Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | 3 | <Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
| 4 | <Import Project="..\..\..\packages\WixToolset.BalUtil.4.0.4\build\WixToolset.BalUtil.props" Condition="Exists('..\..\..\packages\WixToolset.BalUtil.4.0.4\build\WixToolset.BalUtil.props')" /> | 4 | <Import Project="..\..\..\packages\WixToolset.BalUtil.4.0.4\build\WixToolset.BalUtil.props" Condition="Exists('..\..\..\packages\WixToolset.BalUtil.4.0.4\build\WixToolset.BalUtil.props')" /> |
| 5 | <Import Project="..\..\..\packages\WixToolset.BootstrapperCore.4.0.3\build\WixToolset.BootstrapperCore.props" Condition="Exists('..\..\..\packages\WixToolset.BootstrapperCore.4.0.3\build\WixToolset.BootstrapperCore.props')" /> | 5 | <Import Project="..\..\..\packages\WixToolset.BootstrapperCore.4.0.4\build\WixToolset.BootstrapperCore.props" Condition="Exists('..\..\..\packages\WixToolset.BootstrapperCore.4.0.4\build\WixToolset.BootstrapperCore.props')" /> |
| 6 | <Import Project="..\..\..\packages\xunit.core.2.4.0\build\xunit.core.props" Condition="Exists('..\..\..\packages\xunit.core.2.4.0\build\xunit.core.props')" /> | 6 | <Import Project="..\..\..\packages\xunit.core.2.4.0\build\xunit.core.props" Condition="Exists('..\..\..\packages\xunit.core.2.4.0\build\xunit.core.props')" /> |
| 7 | <Import Project="..\..\..\packages\WixToolset.DUtil.4.0.16\build\WixToolset.DUtil.props" Condition="Exists('..\..\..\packages\WixToolset.DUtil.4.0.16\build\WixToolset.DUtil.props')" /> | 7 | <Import Project="..\..\..\packages\WixToolset.DUtil.4.0.16\build\WixToolset.DUtil.props" Condition="Exists('..\..\..\packages\WixToolset.DUtil.4.0.16\build\WixToolset.DUtil.props')" /> |
| 8 | <ItemGroup Label="ProjectConfigurations"> | 8 | <ItemGroup Label="ProjectConfigurations"> |
| @@ -42,6 +42,7 @@ | |||
| 42 | <ClInclude Include="EngineForTest.h" /> | 42 | <ClInclude Include="EngineForTest.h" /> |
| 43 | <ClInclude Include="precomp.h" /> | 43 | <ClInclude Include="precomp.h" /> |
| 44 | <ClInclude Include="TestManagedBootstrapperApplication.h" /> | 44 | <ClInclude Include="TestManagedBootstrapperApplication.h" /> |
| 45 | <ClInclude Include="TestManagedBootstrapperApplicationFactory.h" /> | ||
| 45 | </ItemGroup> | 46 | </ItemGroup> |
| 46 | 47 | ||
| 47 | <ItemGroup> | 48 | <ItemGroup> |
| @@ -65,7 +66,7 @@ | |||
| 65 | <HintPath>..\..\..\packages\xunit.extensibility.execution.2.4.0\lib\net452\xunit.execution.desktop.dll</HintPath> | 66 | <HintPath>..\..\..\packages\xunit.extensibility.execution.2.4.0\lib\net452\xunit.execution.desktop.dll</HintPath> |
| 66 | </Reference> | 67 | </Reference> |
| 67 | <Reference Include="WixToolset.BootstrapperCore"> | 68 | <Reference Include="WixToolset.BootstrapperCore"> |
| 68 | <HintPath>..\..\..\packages\WixToolset.BootstrapperCore.4.0.3\lib\net20\WixToolset.BootstrapperCore.dll</HintPath> | 69 | <HintPath>..\..\..\packages\WixToolset.BootstrapperCore.4.0.4\lib\net20\WixToolset.BootstrapperCore.dll</HintPath> |
| 69 | </Reference> | 70 | </Reference> |
| 70 | </ItemGroup> | 71 | </ItemGroup> |
| 71 | <ItemGroup> | 72 | <ItemGroup> |
| @@ -82,7 +83,7 @@ | |||
| 82 | <ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText> | 83 | <ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText> |
| 83 | </PropertyGroup> | 84 | </PropertyGroup> |
| 84 | <Error Condition="!Exists('..\..\..\packages\WixToolset.BalUtil.4.0.4\build\WixToolset.BalUtil.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\WixToolset.BalUtil.4.0.4\build\WixToolset.BalUtil.props'))" /> | 85 | <Error Condition="!Exists('..\..\..\packages\WixToolset.BalUtil.4.0.4\build\WixToolset.BalUtil.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\WixToolset.BalUtil.4.0.4\build\WixToolset.BalUtil.props'))" /> |
| 85 | <Error Condition="!Exists('..\..\..\packages\WixToolset.BootstrapperCore.4.0.3\build\WixToolset.BootstrapperCore.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\WixToolset.BootstrapperCore.4.0.3\build\WixToolset.BootstrapperCore.props'))" /> | 86 | <Error Condition="!Exists('..\..\..\packages\WixToolset.BootstrapperCore.4.0.4\build\WixToolset.BootstrapperCore.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\WixToolset.BootstrapperCore.4.0.4\build\WixToolset.BootstrapperCore.props'))" /> |
| 86 | <Error Condition="!Exists('..\..\..\packages\xunit.core.2.4.0\build\xunit.core.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\xunit.core.2.4.0\build\xunit.core.props'))" /> | 87 | <Error Condition="!Exists('..\..\..\packages\xunit.core.2.4.0\build\xunit.core.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\xunit.core.2.4.0\build\xunit.core.props'))" /> |
| 87 | <Error Condition="!Exists('..\..\..\packages\xunit.core.2.4.0\build\xunit.core.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\xunit.core.2.4.0\build\xunit.core.targets'))" /> | 88 | <Error Condition="!Exists('..\..\..\packages\xunit.core.2.4.0\build\xunit.core.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\xunit.core.2.4.0\build\xunit.core.targets'))" /> |
| 88 | <Error Condition="!Exists('..\..\..\packages\WixToolset.DUtil.4.0.16\build\WixToolset.DUtil.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\WixToolset.DUtil.4.0.16\build\WixToolset.DUtil.props'))" /> | 89 | <Error Condition="!Exists('..\..\..\packages\WixToolset.DUtil.4.0.16\build\WixToolset.DUtil.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\WixToolset.DUtil.4.0.16\build\WixToolset.DUtil.props'))" /> |
diff --git a/src/test/WixToolsetTest.MbaHost/packages.config b/src/test/WixToolsetTest.MbaHost/packages.config index c3b6551c..d534f781 100644 --- a/src/test/WixToolsetTest.MbaHost/packages.config +++ b/src/test/WixToolsetTest.MbaHost/packages.config | |||
| @@ -9,6 +9,6 @@ | |||
| 9 | <package id="xunit.extensibility.execution" version="2.4.0" targetFramework="net461" /> | 9 | <package id="xunit.extensibility.execution" version="2.4.0" targetFramework="net461" /> |
| 10 | <package id="xunit.runner.visualstudio" version="2.4.0" targetFramework="net461" /> | 10 | <package id="xunit.runner.visualstudio" version="2.4.0" targetFramework="net461" /> |
| 11 | <package id="WixToolset.BalUtil" version="4.0.4" targetFramework="native" /> | 11 | <package id="WixToolset.BalUtil" version="4.0.4" targetFramework="native" /> |
| 12 | <package id="WixToolset.BootstrapperCore" version="4.0.3" targetFramework="net461" /> | 12 | <package id="WixToolset.BootstrapperCore" version="4.0.4" targetFramework="net461" /> |
| 13 | <package id="WixToolset.DUtil" version="4.0.16" targetFramework="native" /> | 13 | <package id="WixToolset.DUtil" version="4.0.16" targetFramework="native" /> |
| 14 | </packages> \ No newline at end of file | 14 | </packages> \ No newline at end of file |
diff --git a/src/test/WixToolsetTest.MbaHost/precomp.h b/src/test/WixToolsetTest.MbaHost/precomp.h index aa4b6ddc..7c451c03 100644 --- a/src/test/WixToolsetTest.MbaHost/precomp.h +++ b/src/test/WixToolsetTest.MbaHost/precomp.h | |||
| @@ -13,3 +13,4 @@ | |||
| 13 | 13 | ||
| 14 | #include "EngineForTest.h" | 14 | #include "EngineForTest.h" |
| 15 | #include "TestManagedBootstrapperApplication.h" | 15 | #include "TestManagedBootstrapperApplication.h" |
| 16 | #include "TestManagedBootstrapperApplicationFactory.h" | ||
