diff options
Diffstat (limited to 'src/test')
7 files changed, 23 insertions, 42 deletions
diff --git a/src/test/WixToolsetTest.MSBuild/MsbuildFixture.cs b/src/test/WixToolsetTest.MSBuild/MsbuildFixture.cs index abb8673d..4a831061 100644 --- a/src/test/WixToolsetTest.MSBuild/MsbuildFixture.cs +++ b/src/test/WixToolsetTest.MSBuild/MsbuildFixture.cs | |||
@@ -11,7 +11,7 @@ namespace WixToolsetTest.MSBuild | |||
11 | 11 | ||
12 | public class MsbuildFixture | 12 | public class MsbuildFixture |
13 | { | 13 | { |
14 | private static readonly string WixTargetsPath = Path.Combine(new Uri(typeof(MsbuildFixture).Assembly.CodeBase).AbsolutePath, "..", "..", "publish", "WixToolset.MSBuild", "tools", "wix.targets"); | 14 | private static readonly string WixPropsPath = Path.Combine(new Uri(typeof(MsbuildFixture).Assembly.CodeBase).AbsolutePath, "..", "..", "publish", "WixToolset.MSBuild", "build", "WixToolset.MSBuild.props"); |
15 | 15 | ||
16 | [Fact] | 16 | [Fact] |
17 | public void CanBuildSimpleBundle() | 17 | public void CanBuildSimpleBundle() |
@@ -27,7 +27,7 @@ namespace WixToolsetTest.MSBuild | |||
27 | 27 | ||
28 | var result = MsbuildRunner.Execute(projectPath, new[] | 28 | var result = MsbuildRunner.Execute(projectPath, new[] |
29 | { | 29 | { |
30 | $"-p:WixTargetsPath={WixTargetsPath}", | 30 | $"-p:WixMSBuildProps={WixPropsPath}", |
31 | }); | 31 | }); |
32 | result.AssertSuccess(); | 32 | result.AssertSuccess(); |
33 | 33 | ||
@@ -63,7 +63,7 @@ namespace WixToolsetTest.MSBuild | |||
63 | 63 | ||
64 | var result = MsbuildRunner.Execute(projectPath, new[] | 64 | var result = MsbuildRunner.Execute(projectPath, new[] |
65 | { | 65 | { |
66 | $"-p:WixTargetsPath={WixTargetsPath}", | 66 | $"-p:WixMSBuildProps={WixPropsPath}", |
67 | }); | 67 | }); |
68 | result.AssertSuccess(); | 68 | result.AssertSuccess(); |
69 | 69 | ||
@@ -124,7 +124,7 @@ namespace WixToolsetTest.MSBuild | |||
124 | var result = MsbuildRunner.Execute(projectPath, new[] | 124 | var result = MsbuildRunner.Execute(projectPath, new[] |
125 | { | 125 | { |
126 | wixpdbType == null ? String.Empty : $"-p:WixPdbType={wixpdbType}", | 126 | wixpdbType == null ? String.Empty : $"-p:WixPdbType={wixpdbType}", |
127 | $"-p:WixTargetsPath={WixTargetsPath}", | 127 | $"-p:WixMSBuildProps={WixPropsPath}", |
128 | }); | 128 | }); |
129 | result.AssertSuccess(); | 129 | result.AssertSuccess(); |
130 | 130 | ||
@@ -150,7 +150,7 @@ namespace WixToolsetTest.MSBuild | |||
150 | 150 | ||
151 | var result = MsbuildRunner.Execute(projectPath, new[] | 151 | var result = MsbuildRunner.Execute(projectPath, new[] |
152 | { | 152 | { |
153 | $"-p:WixTargetsPath={WixTargetsPath}", | 153 | $"-p:WixMSBuildProps={WixPropsPath}", |
154 | $"-p:InstallerPlatform=x64", | 154 | $"-p:InstallerPlatform=x64", |
155 | }); | 155 | }); |
156 | result.AssertSuccess(); | 156 | result.AssertSuccess(); |
@@ -185,7 +185,7 @@ namespace WixToolsetTest.MSBuild | |||
185 | 185 | ||
186 | var result = MsbuildRunner.Execute(projectPath, new[] | 186 | var result = MsbuildRunner.Execute(projectPath, new[] |
187 | { | 187 | { |
188 | $"-p:WixTargetsPath={WixTargetsPath}", | 188 | $"-p:WixMSBuildProps={WixPropsPath}", |
189 | "-p:SuppressIces=\"ICE45;ICE46\"" | 189 | "-p:SuppressIces=\"ICE45;ICE46\"" |
190 | }); | 190 | }); |
191 | result.AssertSuccess(); | 191 | result.AssertSuccess(); |
@@ -206,7 +206,7 @@ namespace WixToolsetTest.MSBuild | |||
206 | 206 | ||
207 | var result = MsbuildRunner.Execute(projectPath, new[] | 207 | var result = MsbuildRunner.Execute(projectPath, new[] |
208 | { | 208 | { |
209 | $"-p:WixTargetsPath={WixTargetsPath}", | 209 | $"-p:WixMSBuildProps={WixPropsPath}", |
210 | "-p:SuppressSpecificWarnings=\"1118;1102\"" | 210 | "-p:SuppressSpecificWarnings=\"1118;1102\"" |
211 | }); | 211 | }); |
212 | result.AssertSuccess(); | 212 | result.AssertSuccess(); |
@@ -230,7 +230,7 @@ namespace WixToolsetTest.MSBuild | |||
230 | 230 | ||
231 | var result = MsbuildRunner.Execute(projectPath, new[] | 231 | var result = MsbuildRunner.Execute(projectPath, new[] |
232 | { | 232 | { |
233 | $"-p:WixTargetsPath={WixTargetsPath}", | 233 | $"-p:WixMSBuildProps={WixPropsPath}", |
234 | "-p:OutputType=IntermediatePostLink" | 234 | "-p:OutputType=IntermediatePostLink" |
235 | }); | 235 | }); |
236 | result.AssertSuccess(); | 236 | result.AssertSuccess(); |
@@ -256,7 +256,7 @@ namespace WixToolsetTest.MSBuild | |||
256 | // Build | 256 | // Build |
257 | var result = MsbuildRunner.Execute(projectPath, new[] | 257 | var result = MsbuildRunner.Execute(projectPath, new[] |
258 | { | 258 | { |
259 | $"-p:WixTargetsPath={WixTargetsPath}", | 259 | $"-p:WixMSBuildProps={WixPropsPath}", |
260 | "-v:diag" | 260 | "-v:diag" |
261 | }); | 261 | }); |
262 | result.AssertSuccess(); | 262 | result.AssertSuccess(); |
@@ -272,7 +272,7 @@ namespace WixToolsetTest.MSBuild | |||
272 | // Clean | 272 | // Clean |
273 | result = MsbuildRunner.Execute(projectPath, new[] | 273 | result = MsbuildRunner.Execute(projectPath, new[] |
274 | { | 274 | { |
275 | $"-p:WixTargetsPath={WixTargetsPath}", | 275 | $"-p:WixMSBuildProps={WixPropsPath}", |
276 | "-t:Clean", | 276 | "-t:Clean", |
277 | "-v:diag" | 277 | "-v:diag" |
278 | }); | 278 | }); |
diff --git a/src/test/WixToolsetTest.MSBuild/MsbuildHeatFixture.cs b/src/test/WixToolsetTest.MSBuild/MsbuildHeatFixture.cs index b5331cbc..58a3d333 100644 --- a/src/test/WixToolsetTest.MSBuild/MsbuildHeatFixture.cs +++ b/src/test/WixToolsetTest.MSBuild/MsbuildHeatFixture.cs | |||
@@ -13,7 +13,7 @@ namespace WixToolsetTest.MSBuild | |||
13 | 13 | ||
14 | public class MsbuildHeatFixture | 14 | public class MsbuildHeatFixture |
15 | { | 15 | { |
16 | private static readonly string WixTargetsPath = Path.Combine(new Uri(typeof(MsbuildHeatFixture).Assembly.CodeBase).AbsolutePath, "..", "..", "publish", "WixToolset.MSBuild", "tools", "wix.targets"); | 16 | private static readonly string WixPropsPath = Path.Combine(new Uri(typeof(MsbuildHeatFixture).Assembly.CodeBase).AbsolutePath, "..", "..", "publish", "WixToolset.MSBuild", "build", "WixToolset.MSBuild.props"); |
17 | 17 | ||
18 | [Fact] | 18 | [Fact] |
19 | public void CanBuildHeatFilePackage() | 19 | public void CanBuildHeatFilePackage() |
@@ -30,7 +30,7 @@ namespace WixToolsetTest.MSBuild | |||
30 | 30 | ||
31 | var result = MsbuildRunner.Execute(projectPath, new[] | 31 | var result = MsbuildRunner.Execute(projectPath, new[] |
32 | { | 32 | { |
33 | $"-p:WixTargetsPath={WixTargetsPath}", | 33 | $"-p:WixMSBuildProps={WixPropsPath}", |
34 | }); | 34 | }); |
35 | result.AssertSuccess(); | 35 | result.AssertSuccess(); |
36 | 36 | ||
@@ -86,7 +86,7 @@ namespace WixToolsetTest.MSBuild | |||
86 | 86 | ||
87 | var result = MsbuildRunner.Execute(projectPath, new[] | 87 | var result = MsbuildRunner.Execute(projectPath, new[] |
88 | { | 88 | { |
89 | $"-p:WixTargetsPath={WixTargetsPath}", | 89 | $"-p:WixMSBuildProps={WixPropsPath}", |
90 | }); | 90 | }); |
91 | result.AssertSuccess(); | 91 | result.AssertSuccess(); |
92 | 92 | ||
diff --git a/src/test/WixToolsetTest.MSBuild/TestData/HeatFileMultipleFilesSameFileName/HeatFileMultipleFilesSameFileName.wixproj b/src/test/WixToolsetTest.MSBuild/TestData/HeatFileMultipleFilesSameFileName/HeatFileMultipleFilesSameFileName.wixproj index 860fc2dd..7d751319 100644 --- a/src/test/WixToolsetTest.MSBuild/TestData/HeatFileMultipleFilesSameFileName/HeatFileMultipleFilesSameFileName.wixproj +++ b/src/test/WixToolsetTest.MSBuild/TestData/HeatFileMultipleFilesSameFileName/HeatFileMultipleFilesSameFileName.wixproj | |||
@@ -1,5 +1,6 @@ | |||
1 | <?xml version="1.0" encoding="utf-8"?> | 1 | <?xml version="1.0" encoding="utf-8"?> |
2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | 2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
3 | <Import Project="$(WixMSBuildProps)" /> | ||
3 | <PropertyGroup> | 4 | <PropertyGroup> |
4 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | 5 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> |
5 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> | 6 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> |
@@ -53,9 +54,5 @@ | |||
53 | </HarvestFile> | 54 | </HarvestFile> |
54 | </ItemGroup> | 55 | </ItemGroup> |
55 | 56 | ||
56 | <Import Project="$(WixTargetsPath)" Condition=" '$(WixTargetsPath)' != '' " /> | 57 | <Import Project="$(WixTargetsPath)" /> |
57 | <Import Project="$(MSBuildExtensionsPath32)\WixToolset\v4.x\wix.targets" Condition=" '$(WixTargetsPath)' == '' AND Exists('$(MSBuildExtensionsPath32)\WixToolset\v4.x\wix.targets') " /> | ||
58 | <Target Name="EnsureWixToolsetInstalled" Condition=" '$(WixTargetsImported)' != 'true' "> | ||
59 | <Error Text="WiX Toolset build tools (v4.0 or later) must be installed to build this project. To download the WiX Toolset, go to http://wixtoolset.org/releases/." /> | ||
60 | </Target> | ||
61 | </Project> \ No newline at end of file | 58 | </Project> \ No newline at end of file |
diff --git a/src/test/WixToolsetTest.MSBuild/TestData/HeatFilePackage/HeatFilePackage.wixproj b/src/test/WixToolsetTest.MSBuild/TestData/HeatFilePackage/HeatFilePackage.wixproj index 87f4388a..3988acaf 100644 --- a/src/test/WixToolsetTest.MSBuild/TestData/HeatFilePackage/HeatFilePackage.wixproj +++ b/src/test/WixToolsetTest.MSBuild/TestData/HeatFilePackage/HeatFilePackage.wixproj | |||
@@ -1,5 +1,6 @@ | |||
1 | <?xml version="1.0" encoding="utf-8"?> | 1 | <?xml version="1.0" encoding="utf-8"?> |
2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | 2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
3 | <Import Project="$(WixMSBuildProps)" /> | ||
3 | <PropertyGroup> | 4 | <PropertyGroup> |
4 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | 5 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> |
5 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> | 6 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> |
@@ -48,9 +49,5 @@ | |||
48 | </HarvestFile> | 49 | </HarvestFile> |
49 | </ItemGroup> | 50 | </ItemGroup> |
50 | 51 | ||
51 | <Import Project="$(WixTargetsPath)" Condition=" '$(WixTargetsPath)' != '' " /> | 52 | <Import Project="$(WixTargetsPath)" /> |
52 | <Import Project="$(MSBuildExtensionsPath32)\WixToolset\v4.x\wix.targets" Condition=" '$(WixTargetsPath)' == '' AND Exists('$(MSBuildExtensionsPath32)\WixToolset\v4.x\wix.targets') " /> | ||
53 | <Target Name="EnsureWixToolsetInstalled" Condition=" '$(WixTargetsImported)' != 'true' "> | ||
54 | <Error Text="WiX Toolset build tools (v4.0 or later) must be installed to build this project. To download the WiX Toolset, go to http://wixtoolset.org/releases/." /> | ||
55 | </Target> | ||
56 | </Project> \ No newline at end of file | 53 | </Project> \ No newline at end of file |
diff --git a/src/test/WixToolsetTest.MSBuild/TestData/MultiCulturalMsiPackage/MsiPackage/MsiPackage.wixproj b/src/test/WixToolsetTest.MSBuild/TestData/MultiCulturalMsiPackage/MsiPackage/MsiPackage.wixproj index e04ea43d..555addbe 100644 --- a/src/test/WixToolsetTest.MSBuild/TestData/MultiCulturalMsiPackage/MsiPackage/MsiPackage.wixproj +++ b/src/test/WixToolsetTest.MSBuild/TestData/MultiCulturalMsiPackage/MsiPackage/MsiPackage.wixproj | |||
@@ -1,5 +1,6 @@ | |||
1 | <?xml version="1.0" encoding="utf-8"?> | 1 | <?xml version="1.0" encoding="utf-8"?> |
2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | 2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
3 | <Import Project="$(WixMSBuildProps)" /> | ||
3 | <PropertyGroup> | 4 | <PropertyGroup> |
4 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | 5 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> |
5 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> | 6 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> |
@@ -12,10 +13,6 @@ | |||
12 | <Cultures>en-US,en;de-DE</Cultures> | 13 | <Cultures>en-US,en;de-DE</Cultures> |
13 | </PropertyGroup> | 14 | </PropertyGroup> |
14 | 15 | ||
15 | <PropertyGroup> | ||
16 | <WixTargetsPath>..\..\..\..\..\..\build\Release\publish\net461\wix.targets</WixTargetsPath> | ||
17 | </PropertyGroup> | ||
18 | |||
19 | <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' "> | 16 | <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' "> |
20 | <PlatformName>$(Platform)</PlatformName> | 17 | <PlatformName>$(Platform)</PlatformName> |
21 | <OutputPath>bin\$(Platform)\$(Configuration)\</OutputPath> | 18 | <OutputPath>bin\$(Platform)\$(Configuration)\</OutputPath> |
@@ -49,9 +46,5 @@ | |||
49 | <BindInputPaths Include="data" /> | 46 | <BindInputPaths Include="data" /> |
50 | </ItemGroup> | 47 | </ItemGroup> |
51 | 48 | ||
52 | <Import Project="$(WixTargetsPath)" Condition=" '$(WixTargetsPath)' != '' " /> | 49 | <Import Project="$(WixTargetsPath)" /> |
53 | <Import Project="$(MSBuildExtensionsPath32)\Microsoft\WiX\v3.x\wix.targets" Condition=" '$(WixTargetsPath)' == '' AND Exists('$(MSBuildExtensionsPath32)\Microsoft\WiX\v3.x\wix.targets') " /> | ||
54 | <Target Name="EnsureWixToolsetInstalled" Condition=" '$(WixTargetsImported)' != 'true' "> | ||
55 | <Error Text="WiX Toolset build tools (v3.11 or later) must be installed to build this project. To download the WiX Toolset, go to http://wixtoolset.org/releases/." /> | ||
56 | </Target> | ||
57 | </Project> | 50 | </Project> |
diff --git a/src/test/WixToolsetTest.MSBuild/TestData/SimpleMsiPackage/MsiPackage/MsiPackage.wixproj b/src/test/WixToolsetTest.MSBuild/TestData/SimpleMsiPackage/MsiPackage/MsiPackage.wixproj index d5cac8d8..18ae08b2 100644 --- a/src/test/WixToolsetTest.MSBuild/TestData/SimpleMsiPackage/MsiPackage/MsiPackage.wixproj +++ b/src/test/WixToolsetTest.MSBuild/TestData/SimpleMsiPackage/MsiPackage/MsiPackage.wixproj | |||
@@ -1,5 +1,6 @@ | |||
1 | <?xml version="1.0" encoding="utf-8"?> | 1 | <?xml version="1.0" encoding="utf-8"?> |
2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | 2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
3 | <Import Project="$(WixMSBuildProps)" /> | ||
3 | <PropertyGroup> | 4 | <PropertyGroup> |
4 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | 5 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> |
5 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> | 6 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> |
@@ -41,9 +42,5 @@ | |||
41 | <BindInputPaths Include="data" /> | 42 | <BindInputPaths Include="data" /> |
42 | </ItemGroup> | 43 | </ItemGroup> |
43 | 44 | ||
44 | <Import Project="$(WixTargetsPath)" Condition=" '$(WixTargetsPath)' != '' " /> | 45 | <Import Project="$(WixTargetsPath)" /> |
45 | <Import Project="$(MSBuildExtensionsPath32)\WixToolset\v4.x\wix.targets" Condition=" '$(WixTargetsPath)' == '' AND Exists('$(MSBuildExtensionsPath32)\WixToolset\v4.x\wix.targets') " /> | ||
46 | <Target Name="EnsureWixToolsetInstalled" Condition=" '$(WixTargetsImported)' != 'true' "> | ||
47 | <Error Text="WiX Toolset build tools (v4.0 or later) must be installed to build this project. To download the WiX Toolset, go to http://wixtoolset.org/releases/." /> | ||
48 | </Target> | ||
49 | </Project> \ No newline at end of file | 46 | </Project> \ No newline at end of file |
diff --git a/src/test/WixToolsetTest.MSBuild/TestData/SimpleMsiPackage/SimpleBundle/SimpleBundle.wixproj b/src/test/WixToolsetTest.MSBuild/TestData/SimpleMsiPackage/SimpleBundle/SimpleBundle.wixproj index 4c837936..199eb6d9 100644 --- a/src/test/WixToolsetTest.MSBuild/TestData/SimpleMsiPackage/SimpleBundle/SimpleBundle.wixproj +++ b/src/test/WixToolsetTest.MSBuild/TestData/SimpleMsiPackage/SimpleBundle/SimpleBundle.wixproj | |||
@@ -1,5 +1,6 @@ | |||
1 | <?xml version="1.0" encoding="utf-8"?> | 1 | <?xml version="1.0" encoding="utf-8"?> |
2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | 2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
3 | <Import Project="$(WixMSBuildProps)" /> | ||
3 | <PropertyGroup> | 4 | <PropertyGroup> |
4 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | 5 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> |
5 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> | 6 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> |
@@ -37,9 +38,5 @@ | |||
37 | <BindInputPaths Include="..\MsiPackage\data" /> | 38 | <BindInputPaths Include="..\MsiPackage\data" /> |
38 | </ItemGroup> | 39 | </ItemGroup> |
39 | 40 | ||
40 | <Import Project="$(WixTargetsPath)" Condition=" '$(WixTargetsPath)' != '' " /> | 41 | <Import Project="$(WixTargetsPath)" /> |
41 | <Import Project="$(MSBuildExtensionsPath32)\WixToolset\v4.x\wix.targets" Condition=" '$(WixTargetsPath)' == '' AND Exists('$(MSBuildExtensionsPath32)\WixToolset\v4.x\wix.targets') " /> | ||
42 | <Target Name="EnsureWixToolsetInstalled" Condition=" '$(WixTargetsImported)' != 'true' "> | ||
43 | <Error Text="WiX Toolset build tools (v4.0 or later) must be installed to build this project. To download the WiX Toolset, go to http://wixtoolset.org/releases/." /> | ||
44 | </Target> | ||
45 | </Project> \ No newline at end of file | 42 | </Project> \ No newline at end of file |