diff options
Diffstat (limited to '')
7 files changed, 145 insertions, 0 deletions
diff --git a/src/test/WixToolsetTest.BuildTasks/WixToolsetTest.BuildTasks.csproj b/src/test/WixToolsetTest.BuildTasks/WixToolsetTest.BuildTasks.csproj new file mode 100644 index 00000000..46bbf4cf --- /dev/null +++ b/src/test/WixToolsetTest.BuildTasks/WixToolsetTest.BuildTasks.csproj | |||
@@ -0,0 +1,21 @@ | |||
1 | <?xml version="1.0" encoding="utf-8"?> | ||
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 | <Project Sdk="Microsoft.NET.Sdk"> | ||
5 | <PropertyGroup> | ||
6 | <TargetFramework>netcoreapp2.0</TargetFramework> | ||
7 | <Description></Description> | ||
8 | <Title>WiX Toolset Tests for MSBuild Tasks</Title> | ||
9 | </PropertyGroup> | ||
10 | |||
11 | <PropertyGroup> | ||
12 | </PropertyGroup> | ||
13 | |||
14 | <ItemGroup> | ||
15 | <!-- <ProjectReference Include="..\..\WixToolset.BuildTasks\WixToolset.BuildTasks.csproj" /> --> | ||
16 | </ItemGroup> | ||
17 | |||
18 | <ItemGroup> | ||
19 | <PackageReference Include="Nerdbank.GitVersioning" Version="2.0.41" PrivateAssets="all" /> | ||
20 | </ItemGroup> | ||
21 | </Project> | ||
diff --git a/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/MsiPackage.wixproj b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/MsiPackage.wixproj new file mode 100644 index 00000000..cd956964 --- /dev/null +++ b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/MsiPackage.wixproj | |||
@@ -0,0 +1,51 @@ | |||
1 | <?xml version="1.0" encoding="utf-8"?> | ||
2 | <Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
3 | <PropertyGroup> | ||
4 | <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | ||
5 | <Platform Condition=" '$(Platform)' == '' ">x86</Platform> | ||
6 | <ProductVersion>0.9</ProductVersion> | ||
7 | <ProjectGuid>7fb77005-c6e0-454f-8c2d-0a4a79c918ba</ProjectGuid> | ||
8 | <OutputName>MsiPackage</OutputName> | ||
9 | <OutputType>Package</OutputType> | ||
10 | <Name>MsiPackage</Name> | ||
11 | <RootNamespace>MsiPackage</RootNamespace> | ||
12 | </PropertyGroup> | ||
13 | |||
14 | <PropertyGroup> | ||
15 | <WixTargetsPath>..\..\..\..\..\..\build\Debug\net462\wix.targets</WixTargetsPath> | ||
16 | <WixTargetsPath>..\..\..\..\..\..\build\Debug\netstandard2.0\wix.targets</WixTargetsPath> | ||
17 | <WixTargetsPath>..\..\..\..\..\..\build\publish\wix.targets</WixTargetsPath> | ||
18 | <WixTargetsPath>..\..\..\..\..\..\build\Debug\net462\wix.targets</WixTargetsPath> | ||
19 | </PropertyGroup> | ||
20 | |||
21 | <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' "> | ||
22 | <PlatformName>$(Platform)</PlatformName> | ||
23 | <OutputPath>bin\$(Platform)\$(Configuration)\</OutputPath> | ||
24 | <DefineConstants>Debug</DefineConstants> | ||
25 | </PropertyGroup> | ||
26 | <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' "> | ||
27 | <PlatformName>$(Platform)</PlatformName> | ||
28 | <OutputPath>bin\$(Platform)\$(Configuration)\</OutputPath> | ||
29 | </PropertyGroup> | ||
30 | <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x64' "> | ||
31 | <PlatformName>$(Platform)</PlatformName> | ||
32 | <OutputPath>bin\$(Platform)\$(Configuration)\</OutputPath> | ||
33 | <DefineConstants>Debug</DefineConstants> | ||
34 | </PropertyGroup> | ||
35 | <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x64' "> | ||
36 | <PlatformName>$(Platform)</PlatformName> | ||
37 | <OutputPath>bin\$(Platform)\$(Configuration)\</OutputPath> | ||
38 | </PropertyGroup> | ||
39 | <ItemGroup> | ||
40 | <Compile Include="Package.wxs" /> | ||
41 | <Compile Include="PackageComponents.wxs" /> | ||
42 | </ItemGroup> | ||
43 | <ItemGroup> | ||
44 | <EmbeddedResource Include="Package.en-us.wxl" /> | ||
45 | </ItemGroup> | ||
46 | <Import Project="$(WixTargetsPath)" Condition=" '$(WixTargetsPath)' != '' " /> | ||
47 | <Import Project="$(MSBuildExtensionsPath32)\Microsoft\WiX\v3.x\wix.targets" Condition=" '$(WixTargetsPath)' == '' AND Exists('$(MSBuildExtensionsPath32)\Microsoft\WiX\v3.x\wix.targets') " /> | ||
48 | <Target Name="EnsureWixToolsetInstalled" Condition=" '$(WixTargetsImported)' != 'true' "> | ||
49 | <Error Text="FG-WiX or WiX Toolset build tools (v3.11 or later) must be installed to build this project. To download FG-WiX, go to https://www.firegiant.com/downloads/. To download the WiX Toolset, go to http://wixtoolset.org/releases/." /> | ||
50 | </Target> | ||
51 | </Project> \ No newline at end of file | ||
diff --git a/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/Package.en-us.wxl b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/Package.en-us.wxl new file mode 100644 index 00000000..38c12ac1 --- /dev/null +++ b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/Package.en-us.wxl | |||
@@ -0,0 +1,11 @@ | |||
1 | <?xml version="1.0" encoding="utf-8"?> | ||
2 | |||
3 | <!-- | ||
4 | This file contains the declaration of all the localizable strings. | ||
5 | --> | ||
6 | <WixLocalization xmlns="http://wixtoolset.org/schemas/v4/wxl" Culture="en-US"> | ||
7 | |||
8 | <String Id="DowngradeError">A newer version of [ProductName] is already installed.</String> | ||
9 | <String Id="FeatureTitle">MsiPackage</String> | ||
10 | |||
11 | </WixLocalization> | ||
diff --git a/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/Package.wxs b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/Package.wxs new file mode 100644 index 00000000..d5a5a40d --- /dev/null +++ b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/Package.wxs | |||
@@ -0,0 +1,21 @@ | |||
1 | <?xml version="1.0" encoding="utf-8"?> | ||
2 | <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"> | ||
3 | <Product Id="*" Name="MsiPackage" Language="1033" Version="1.0.0.0" Manufacturer="Example Corporation" UpgradeCode="047730a5-30fe-4a62-a520-da9381b8226a"> | ||
4 | <Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" /> | ||
5 | |||
6 | <MajorUpgrade DowngradeErrorMessage="!(loc.DowngradeError)" /> | ||
7 | <MediaTemplate /> | ||
8 | |||
9 | <Feature Id="ProductFeature" Title="!(loc.FeatureTitle)"> | ||
10 | <ComponentGroupRef Id="ProductComponents" /> | ||
11 | </Feature> | ||
12 | </Product> | ||
13 | |||
14 | <Fragment> | ||
15 | <Directory Id="TARGETDIR" Name="SourceDir"> | ||
16 | <Directory Id="ProgramFilesFolder"> | ||
17 | <Directory Id="INSTALLFOLDER" Name="MsiPackage" /> | ||
18 | </Directory> | ||
19 | </Directory> | ||
20 | </Fragment> | ||
21 | </Wix> | ||
diff --git a/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/PackageComponents.wxs b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/PackageComponents.wxs new file mode 100644 index 00000000..76a12a9a --- /dev/null +++ b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/PackageComponents.wxs | |||
@@ -0,0 +1,10 @@ | |||
1 | <?xml version="1.0" encoding="utf-8"?> | ||
2 | <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"> | ||
3 | <Fragment> | ||
4 | <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER"> | ||
5 | <Component> | ||
6 | <File Source="Package.wxs" /> | ||
7 | </Component> | ||
8 | </ComponentGroup> | ||
9 | </Fragment> | ||
10 | </Wix> | ||
diff --git a/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/i.txt b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/i.txt new file mode 100644 index 00000000..53f23c98 --- /dev/null +++ b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/MsiPackage/i.txt | |||
Binary files differ | |||
diff --git a/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/SimpleMsiPackage.sln b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/SimpleMsiPackage.sln new file mode 100644 index 00000000..2c88704e --- /dev/null +++ b/src/test/WixToolsetTest.BuildTasks/data/SimpleMsiPackage/SimpleMsiPackage.sln | |||
@@ -0,0 +1,31 @@ | |||
1 | | ||
2 | Microsoft Visual Studio Solution File, Format Version 12.00 | ||
3 | # Visual Studio 15 | ||
4 | VisualStudioVersion = 15.0.26730.8 | ||
5 | MinimumVisualStudioVersion = 10.0.40219.1 | ||
6 | Project("{930C7802-8A8C-48F9-8165-68863BCCD9DD}") = "MsiPackage", "MsiPackage\MsiPackage.wixproj", "{7FB77005-C6E0-454F-8C2D-0A4A79C918BA}" | ||
7 | EndProject | ||
8 | Global | ||
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution | ||
10 | Debug|x64 = Debug|x64 | ||
11 | Debug|x86 = Debug|x86 | ||
12 | Release|x64 = Release|x64 | ||
13 | Release|x86 = Release|x86 | ||
14 | EndGlobalSection | ||
15 | GlobalSection(ProjectConfigurationPlatforms) = postSolution | ||
16 | {7FB77005-C6E0-454F-8C2D-0A4A79C918BA}.Debug|x64.ActiveCfg = Debug|x64 | ||
17 | {7FB77005-C6E0-454F-8C2D-0A4A79C918BA}.Debug|x64.Build.0 = Debug|x64 | ||
18 | {7FB77005-C6E0-454F-8C2D-0A4A79C918BA}.Debug|x86.ActiveCfg = Debug|x86 | ||
19 | {7FB77005-C6E0-454F-8C2D-0A4A79C918BA}.Debug|x86.Build.0 = Debug|x86 | ||
20 | {7FB77005-C6E0-454F-8C2D-0A4A79C918BA}.Release|x64.ActiveCfg = Release|x64 | ||
21 | {7FB77005-C6E0-454F-8C2D-0A4A79C918BA}.Release|x64.Build.0 = Release|x64 | ||
22 | {7FB77005-C6E0-454F-8C2D-0A4A79C918BA}.Release|x86.ActiveCfg = Release|x86 | ||
23 | {7FB77005-C6E0-454F-8C2D-0A4A79C918BA}.Release|x86.Build.0 = Release|x86 | ||
24 | EndGlobalSection | ||
25 | GlobalSection(SolutionProperties) = preSolution | ||
26 | HideSolutionNode = FALSE | ||
27 | EndGlobalSection | ||
28 | GlobalSection(ExtensibilityGlobals) = postSolution | ||
29 | SolutionGuid = {585B0599-4EB5-4AB6-BC66-819CC78B63D5} | ||
30 | EndGlobalSection | ||
31 | EndGlobal | ||