diff options
| author | Rob Mensching <rob@firegiant.com> | 2021-05-03 17:00:34 -0700 |
|---|---|---|
| committer | Rob Mensching <rob@firegiant.com> | 2021-05-03 17:00:34 -0700 |
| commit | 592c6e2f7407c291a7bf9ef4c8ce50da9798cc68 (patch) | |
| tree | af42d0518b91cdc31590884006a2624bf7cdf4ed /src/test | |
| parent | 0e7fa93306858a9adde5b64ede920492632ba9e6 (diff) | |
| download | wix-592c6e2f7407c291a7bf9ef4c8ce50da9798cc68.tar.gz wix-592c6e2f7407c291a7bf9ef4c8ce50da9798cc68.tar.bz2 wix-592c6e2f7407c291a7bf9ef4c8ce50da9798cc68.zip | |
Move UI.wixext into ext
Diffstat (limited to 'src/test')
8 files changed, 0 insertions, 274 deletions
diff --git a/src/test/WixToolsetTest.UI/TestData/WixUI_Advanced/Package.wxs b/src/test/WixToolsetTest.UI/TestData/WixUI_Advanced/Package.wxs deleted file mode 100644 index 5ce4b00f..00000000 --- a/src/test/WixToolsetTest.UI/TestData/WixUI_Advanced/Package.wxs +++ /dev/null | |||
| @@ -1,27 +0,0 @@ | |||
| 1 | <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"> | ||
| 2 | <Package Name="MsiPackage" Language="1033" Version="1.0.0.0" Manufacturer="Example Corporation" UpgradeCode="047730a5-30fe-4a62-a520-da9381b8226a" InstallerVersion="200"> | ||
| 3 | <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." /> | ||
| 4 | |||
| 5 | <Feature Id="ProductFeature" Title="MsiPackage"> | ||
| 6 | <ComponentGroupRef Id="ProductComponents" /> | ||
| 7 | </Feature> | ||
| 8 | |||
| 9 | <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER"> | ||
| 10 | <Component> | ||
| 11 | <File Source="example.txt" /> | ||
| 12 | </Component> | ||
| 13 | </ComponentGroup> | ||
| 14 | |||
| 15 | <UIRef Id="WixUI_Advanced" /> | ||
| 16 | <Property Id="ApplicationFolderName" Value="MyProgram" /> | ||
| 17 | <Property Id="WixAppFolder" Value="WixPerMachineFolder" /> | ||
| 18 | </Package> | ||
| 19 | |||
| 20 | <Fragment> | ||
| 21 | <StandardDirectory Id="ProgramFilesFolder"> | ||
| 22 | <Directory Id="INSTALLFOLDER" Name="MsiPackage"> | ||
| 23 | <Directory Id="APPLICATIONFOLDER" /> | ||
| 24 | </Directory> | ||
| 25 | </StandardDirectory> | ||
| 26 | </Fragment> | ||
| 27 | </Wix> | ||
diff --git a/src/test/WixToolsetTest.UI/TestData/WixUI_FeatureTree/Package.wxs b/src/test/WixToolsetTest.UI/TestData/WixUI_FeatureTree/Package.wxs deleted file mode 100644 index aff1c077..00000000 --- a/src/test/WixToolsetTest.UI/TestData/WixUI_FeatureTree/Package.wxs +++ /dev/null | |||
| @@ -1,23 +0,0 @@ | |||
| 1 | <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"> | ||
| 2 | <Package Name="MsiPackage" Language="1033" Version="1.0.0.0" Manufacturer="Example Corporation" UpgradeCode="047730a5-30fe-4a62-a520-da9381b8226a" InstallerVersion="200"> | ||
| 3 | <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." /> | ||
| 4 | |||
| 5 | <Feature Id="ProductFeature" Title="MsiPackage"> | ||
| 6 | <ComponentGroupRef Id="ProductComponents" /> | ||
| 7 | </Feature> | ||
| 8 | |||
| 9 | <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER"> | ||
| 10 | <Component> | ||
| 11 | <File Source="example.txt" /> | ||
| 12 | </Component> | ||
| 13 | </ComponentGroup> | ||
| 14 | |||
| 15 | <UIRef Id="WixUI_FeatureTree" /> | ||
| 16 | </Package> | ||
| 17 | |||
| 18 | <Fragment> | ||
| 19 | <StandardDirectory Id="ProgramFilesFolder"> | ||
| 20 | <Directory Id="INSTALLFOLDER" Name="MsiPackage" /> | ||
| 21 | </StandardDirectory> | ||
| 22 | </Fragment> | ||
| 23 | </Wix> | ||
diff --git a/src/test/WixToolsetTest.UI/TestData/WixUI_InstallDir/Package.wxs b/src/test/WixToolsetTest.UI/TestData/WixUI_InstallDir/Package.wxs deleted file mode 100644 index 7c2ceae0..00000000 --- a/src/test/WixToolsetTest.UI/TestData/WixUI_InstallDir/Package.wxs +++ /dev/null | |||
| @@ -1,23 +0,0 @@ | |||
| 1 | <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"> | ||
| 2 | <Package Name="MsiPackage" Language="1033" Version="1.0.0.0" Manufacturer="Example Corporation" UpgradeCode="047730a5-30fe-4a62-a520-da9381b8226a" InstallerVersion="200"> | ||
| 3 | <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." /> | ||
| 4 | |||
| 5 | <Feature Id="ProductFeature" Title="MsiPackage"> | ||
| 6 | <ComponentGroupRef Id="ProductComponents" /> | ||
| 7 | </Feature> | ||
| 8 | |||
| 9 | <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER"> | ||
| 10 | <Component> | ||
| 11 | <File Source="example.txt" /> | ||
| 12 | </Component> | ||
| 13 | </ComponentGroup> | ||
| 14 | |||
| 15 | <UIRef Id="WixUI_InstallDir" /> | ||
| 16 | </Package> | ||
| 17 | |||
| 18 | <Fragment> | ||
| 19 | <StandardDirectory Id="ProgramFilesFolder"> | ||
| 20 | <Directory Id="INSTALLFOLDER" Name="MsiPackage" /> | ||
| 21 | </StandardDirectory> | ||
| 22 | </Fragment> | ||
| 23 | </Wix> | ||
diff --git a/src/test/WixToolsetTest.UI/TestData/WixUI_Minimal/Package.wxs b/src/test/WixToolsetTest.UI/TestData/WixUI_Minimal/Package.wxs deleted file mode 100644 index d2ff256c..00000000 --- a/src/test/WixToolsetTest.UI/TestData/WixUI_Minimal/Package.wxs +++ /dev/null | |||
| @@ -1,23 +0,0 @@ | |||
| 1 | <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"> | ||
| 2 | <Package Name="MsiPackage" Language="1033" Version="1.0.0.0" Manufacturer="Example Corporation" UpgradeCode="047730a5-30fe-4a62-a520-da9381b8226a" InstallerVersion="200"> | ||
| 3 | <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." /> | ||
| 4 | |||
| 5 | <Feature Id="ProductFeature" Title="MsiPackage"> | ||
| 6 | <ComponentGroupRef Id="ProductComponents" /> | ||
| 7 | </Feature> | ||
| 8 | |||
| 9 | <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER"> | ||
| 10 | <Component> | ||
| 11 | <File Source="example.txt" /> | ||
| 12 | </Component> | ||
| 13 | </ComponentGroup> | ||
| 14 | |||
| 15 | <UIRef Id="WixUI_Minimal" /> | ||
| 16 | </Package> | ||
| 17 | |||
| 18 | <Fragment> | ||
| 19 | <StandardDirectory Id="ProgramFilesFolder"> | ||
| 20 | <Directory Id="INSTALLFOLDER" Name="MsiPackage" /> | ||
| 21 | </StandardDirectory> | ||
| 22 | </Fragment> | ||
| 23 | </Wix> | ||
diff --git a/src/test/WixToolsetTest.UI/TestData/WixUI_Mondo/Package.wxs b/src/test/WixToolsetTest.UI/TestData/WixUI_Mondo/Package.wxs deleted file mode 100644 index 8d5a856a..00000000 --- a/src/test/WixToolsetTest.UI/TestData/WixUI_Mondo/Package.wxs +++ /dev/null | |||
| @@ -1,23 +0,0 @@ | |||
| 1 | <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"> | ||
| 2 | <Package Name="MsiPackage" Language="1033" Version="1.0.0.0" Manufacturer="Example Corporation" UpgradeCode="047730a5-30fe-4a62-a520-da9381b8226a" InstallerVersion="200"> | ||
| 3 | <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." /> | ||
| 4 | |||
| 5 | <Feature Id="ProductFeature" Title="MsiPackage"> | ||
| 6 | <ComponentGroupRef Id="ProductComponents" /> | ||
| 7 | </Feature> | ||
| 8 | |||
| 9 | <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER"> | ||
| 10 | <Component> | ||
| 11 | <File Source="example.txt" /> | ||
| 12 | </Component> | ||
| 13 | </ComponentGroup> | ||
| 14 | |||
| 15 | <UIRef Id="WixUI_Mondo" /> | ||
| 16 | </Package> | ||
| 17 | |||
| 18 | <Fragment> | ||
| 19 | <StandardDirectory Id="ProgramFilesFolder"> | ||
| 20 | <Directory Id="INSTALLFOLDER" Name="MsiPackage" /> | ||
| 21 | </StandardDirectory> | ||
| 22 | </Fragment> | ||
| 23 | </Wix> | ||
diff --git a/src/test/WixToolsetTest.UI/TestData/data/example.txt b/src/test/WixToolsetTest.UI/TestData/data/example.txt deleted file mode 100644 index 1b4ffe8a..00000000 --- a/src/test/WixToolsetTest.UI/TestData/data/example.txt +++ /dev/null | |||
| @@ -1 +0,0 @@ | |||
| 1 | This is example.txt. \ No newline at end of file | ||
diff --git a/src/test/WixToolsetTest.UI/UIExtensionFixture.cs b/src/test/WixToolsetTest.UI/UIExtensionFixture.cs deleted file mode 100644 index 54c4c788..00000000 --- a/src/test/WixToolsetTest.UI/UIExtensionFixture.cs +++ /dev/null | |||
| @@ -1,111 +0,0 @@ | |||
| 1 | // 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 | |||
| 3 | namespace WixToolsetTest.UI | ||
| 4 | { | ||
| 5 | using System.Linq; | ||
| 6 | using WixBuildTools.TestSupport; | ||
| 7 | using WixToolset.Core.TestPackage; | ||
| 8 | using WixToolset.UI; | ||
| 9 | using Xunit; | ||
| 10 | |||
| 11 | public class UIExtensionFixture | ||
| 12 | { | ||
| 13 | [Fact] | ||
| 14 | public void CanBuildUsingWixUIAdvanced() | ||
| 15 | { | ||
| 16 | var folder = TestData.Get(@"TestData\WixUI_Advanced"); | ||
| 17 | var bindFolder = TestData.Get(@"TestData\data"); | ||
| 18 | var build = new Builder(folder, typeof(UIExtensionFactory), new[] { bindFolder }); | ||
| 19 | |||
| 20 | var results = build.BuildAndQuery(Build, "Property"); | ||
| 21 | Assert.Equal(new[] | ||
| 22 | { | ||
| 23 | "Property:WixUI_Mode\tAdvanced", | ||
| 24 | }, results.Where(s => s.StartsWith("Property:WixUI_Mode")).ToArray()); | ||
| 25 | } | ||
| 26 | |||
| 27 | [Fact] | ||
| 28 | public void CanBuildUsingWixUIFeatureTree() | ||
| 29 | { | ||
| 30 | var folder = TestData.Get(@"TestData\WixUI_FeatureTree"); | ||
| 31 | var bindFolder = TestData.Get(@"TestData\data"); | ||
| 32 | var build = new Builder(folder, typeof(UIExtensionFactory), new[] { bindFolder }); | ||
| 33 | |||
| 34 | var results = build.BuildAndQuery(Build, "Property"); | ||
| 35 | Assert.Equal(new[] | ||
| 36 | { | ||
| 37 | "Property:WixUI_Mode\tFeatureTree", | ||
| 38 | }, results.Where(s => s.StartsWith("Property:WixUI_Mode")).ToArray()); | ||
| 39 | } | ||
| 40 | |||
| 41 | [Fact] | ||
| 42 | public void CanBuildUsingWixUIInstallDir() | ||
| 43 | { | ||
| 44 | var folder = TestData.Get(@"TestData\WixUI_InstallDir"); | ||
| 45 | var bindFolder = TestData.Get(@"TestData\data"); | ||
| 46 | var build = new Builder(folder, typeof(UIExtensionFactory), new[] { bindFolder }); | ||
| 47 | |||
| 48 | var results = build.BuildAndQuery(Build, "Property"); | ||
| 49 | Assert.Equal(new[] | ||
| 50 | { | ||
| 51 | "Property:WixUI_Mode\tInstallDir", | ||
| 52 | }, results.Where(s => s.StartsWith("Property:WixUI_Mode")).ToArray()); | ||
| 53 | } | ||
| 54 | |||
| 55 | [Fact] | ||
| 56 | public void CanBuildUsingWixUIMinimal() | ||
| 57 | { | ||
| 58 | var folder = TestData.Get(@"TestData\WixUI_Minimal"); | ||
| 59 | var bindFolder = TestData.Get(@"TestData\data"); | ||
| 60 | var build = new Builder(folder, typeof(UIExtensionFactory), new[] { bindFolder }); | ||
| 61 | |||
| 62 | var results = build.BuildAndQuery(Build, "Property"); | ||
| 63 | Assert.Equal(new[] | ||
| 64 | { | ||
| 65 | "Property:WixUI_Mode\tMinimal", | ||
| 66 | }, results.Where(s => s.StartsWith("Property:WixUI_Mode")).ToArray()); | ||
| 67 | } | ||
| 68 | |||
| 69 | [Fact] | ||
| 70 | public void CanBuildUsingWixUIMondo() | ||
| 71 | { | ||
| 72 | var folder = TestData.Get(@"TestData\WixUI_Mondo"); | ||
| 73 | var bindFolder = TestData.Get(@"TestData\data"); | ||
| 74 | var build = new Builder(folder, typeof(UIExtensionFactory), new[] { bindFolder }); | ||
| 75 | |||
| 76 | var results = build.BuildAndQuery(Build, "Property"); | ||
| 77 | Assert.Equal(new[] | ||
| 78 | { | ||
| 79 | "Property:WixUI_Mode\tMondo", | ||
| 80 | }, results.Where(s => s.StartsWith("Property:WixUI_Mode")).ToArray()); | ||
| 81 | } | ||
| 82 | |||
| 83 | [Fact] | ||
| 84 | public void CanBuildUsingWixUIMondoLocalized() | ||
| 85 | { | ||
| 86 | var folder = TestData.Get(@"TestData\WixUI_Mondo"); | ||
| 87 | var bindFolder = TestData.Get(@"TestData\data"); | ||
| 88 | var build = new Builder(folder, typeof(UIExtensionFactory), new[] { bindFolder }); | ||
| 89 | |||
| 90 | var results = build.BuildAndQuery(BuildInGerman, "Control"); | ||
| 91 | Assert.Equal(new[] | ||
| 92 | { | ||
| 93 | "&Ja", | ||
| 94 | }, results.Where(s => s.StartsWith("Control:ErrorDlg\tY")).Select(s => s.Split('\t')[9]).ToArray()); | ||
| 95 | } | ||
| 96 | |||
| 97 | private static void Build(string[] args) | ||
| 98 | { | ||
| 99 | var result = WixRunner.Execute(args) | ||
| 100 | .AssertSuccess(); | ||
| 101 | } | ||
| 102 | |||
| 103 | private static void BuildInGerman(string[] args) | ||
| 104 | { | ||
| 105 | var localizedArgs = args.Append("-culture").Append("de-DE").ToArray(); | ||
| 106 | |||
| 107 | var result = WixRunner.Execute(localizedArgs) | ||
| 108 | .AssertSuccess(); | ||
| 109 | } | ||
| 110 | } | ||
| 111 | } | ||
diff --git a/src/test/WixToolsetTest.UI/WixToolsetTest.UI.csproj b/src/test/WixToolsetTest.UI/WixToolsetTest.UI.csproj deleted file mode 100644 index a61676dd..00000000 --- a/src/test/WixToolsetTest.UI/WixToolsetTest.UI.csproj +++ /dev/null | |||
| @@ -1,43 +0,0 @@ | |||
| 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>netcoreapp3.1</TargetFramework> | ||
| 7 | <IsPackable>false</IsPackable> | ||
| 8 | </PropertyGroup> | ||
| 9 | |||
| 10 | <PropertyGroup> | ||
| 11 | <NoWarn>NU1701</NoWarn> | ||
| 12 | </PropertyGroup> | ||
| 13 | |||
| 14 | <ItemGroup> | ||
| 15 | <Content Include="TestData\data\example.txt" CopyToOutputDirectory="PreserveNewest" /> | ||
| 16 | <Content Include="TestData\WixUI_Advanced\Package.wxs" CopyToOutputDirectory="PreserveNewest" /> | ||
| 17 | <Content Include="TestData\WixUI_FeatureTree\Package.wxs" CopyToOutputDirectory="PreserveNewest" /> | ||
| 18 | <Content Include="TestData\WixUI_InstallDir\Package.wxs" CopyToOutputDirectory="PreserveNewest" /> | ||
| 19 | <Content Include="TestData\WixUI_Minimal\Package.wxs" CopyToOutputDirectory="PreserveNewest" /> | ||
| 20 | <Content Include="TestData\WixUI_Mondo\Package.wxs" CopyToOutputDirectory="PreserveNewest" /> | ||
| 21 | </ItemGroup> | ||
| 22 | |||
| 23 | <ItemGroup> | ||
| 24 | <ProjectReference Include="..\..\wixext\WixToolset.UI.wixext.csproj" /> | ||
| 25 | </ItemGroup> | ||
| 26 | |||
| 27 | <ItemGroup> | ||
| 28 | <PackageReference Include="WixToolset.Core" Version="4.0.*" /> | ||
| 29 | <PackageReference Include="WixToolset.Core.Burn" Version="4.0.*" /> | ||
| 30 | <PackageReference Include="WixToolset.Core.WindowsInstaller" Version="4.0.*" /> | ||
| 31 | <PackageReference Include="WixToolset.Core.TestPackage" Version="4.0.*" /> | ||
| 32 | </ItemGroup> | ||
| 33 | |||
| 34 | <ItemGroup> | ||
| 35 | <PackageReference Include="WixBuildTools.TestSupport" Version="4.0.*" /> | ||
| 36 | </ItemGroup> | ||
| 37 | |||
| 38 | <ItemGroup> | ||
| 39 | <PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.8.3" /> | ||
| 40 | <PackageReference Include="xunit" Version="2.4.1" /> | ||
| 41 | <PackageReference Include="xunit.runner.visualstudio" Version="2.4.3" PrivateAssets="All" /> | ||
| 42 | </ItemGroup> | ||
| 43 | </Project> | ||
