diff options
Diffstat (limited to 'src/test/WixToolsetTest.CoreIntegration')
4 files changed, 127 insertions, 0 deletions
diff --git a/src/test/WixToolsetTest.CoreIntegration/MsiQueryFixture.cs b/src/test/WixToolsetTest.CoreIntegration/MsiQueryFixture.cs index e60f74fb..2c064a58 100644 --- a/src/test/WixToolsetTest.CoreIntegration/MsiQueryFixture.cs +++ b/src/test/WixToolsetTest.CoreIntegration/MsiQueryFixture.cs | |||
| @@ -412,6 +412,42 @@ namespace WixToolsetTest.CoreIntegration | |||
| 412 | } | 412 | } |
| 413 | 413 | ||
| 414 | [Fact(Skip = "Test demonstrates failure")] | 414 | [Fact(Skip = "Test demonstrates failure")] |
| 415 | public void PopulatesMsiAssemblyTables() | ||
| 416 | { | ||
| 417 | var folder = TestData.Get(@"TestData"); | ||
| 418 | |||
| 419 | using (var fs = new DisposableFileSystem()) | ||
| 420 | { | ||
| 421 | var baseFolder = fs.GetFolder(); | ||
| 422 | var intermediateFolder = Path.Combine(baseFolder, "obj"); | ||
| 423 | var msiPath = Path.Combine(baseFolder, @"bin\test.msi"); | ||
| 424 | |||
| 425 | var result = WixRunner.Execute(new[] | ||
| 426 | { | ||
| 427 | "build", | ||
| 428 | Path.Combine(folder, "Assembly", "Win32Assembly.wxs"), | ||
| 429 | Path.Combine(folder, "ProductWithComponentGroupRef", "MinimalComponentGroup.wxs"), | ||
| 430 | Path.Combine(folder, "ProductWithComponentGroupRef", "Product.wxs"), | ||
| 431 | "-bindpath", Path.Combine(folder, "Assembly", "data"), | ||
| 432 | "-bindpath", Path.Combine(folder, "SingleFile", "data"), | ||
| 433 | "-intermediateFolder", intermediateFolder, | ||
| 434 | "-o", msiPath | ||
| 435 | }); | ||
| 436 | |||
| 437 | result.AssertSuccess(); | ||
| 438 | |||
| 439 | Assert.True(File.Exists(msiPath)); | ||
| 440 | var results = Query.QueryDatabase(msiPath, new[] { "MsiAssembly", "MsiAssemblyName" }); | ||
| 441 | Assert.Equal(new[] | ||
| 442 | { | ||
| 443 | "MsiAssembly:test.txt\tProductFeature\ttest.dll.manifest\t\t1", | ||
| 444 | "MsiAssemblyName:test.txt\tname\tMyApplication.app", | ||
| 445 | "MsiAssemblyName:test.txt\tversion\t1.0.0.0", | ||
| 446 | }, results); | ||
| 447 | } | ||
| 448 | } | ||
| 449 | |||
| 450 | [Fact(Skip = "Test demonstrates failure")] | ||
| 415 | public void PopulatesMsiShortcutPropertyTable() | 451 | public void PopulatesMsiShortcutPropertyTable() |
| 416 | { | 452 | { |
| 417 | var folder = TestData.Get(@"TestData"); | 453 | var folder = TestData.Get(@"TestData"); |
diff --git a/src/test/WixToolsetTest.CoreIntegration/TestData/Assembly/Win32Assembly.wxs b/src/test/WixToolsetTest.CoreIntegration/TestData/Assembly/Win32Assembly.wxs new file mode 100644 index 00000000..980c5ca4 --- /dev/null +++ b/src/test/WixToolsetTest.CoreIntegration/TestData/Assembly/Win32Assembly.wxs | |||
| @@ -0,0 +1,13 @@ | |||
| 1 | <?xml version="1.0" encoding="utf-8"?> | ||
| 2 | <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"> | ||
| 3 | <Fragment> | ||
| 4 | <ComponentGroup Id="ProductComponents"> | ||
| 5 | <Component Directory="INSTALLFOLDER"> | ||
| 6 | <File Source="test.txt" Assembly="win32" AssemblyManifest="test.dll.manifest" /> | ||
| 7 | </Component> | ||
| 8 | <Component Id="test.dll.manifest" Directory="INSTALLFOLDER"> | ||
| 9 | <File Id="test.dll.manifest" Source="test.manifest" Name="test.dll.manifest"></File> | ||
| 10 | </Component> | ||
| 11 | </ComponentGroup> | ||
| 12 | </Fragment> | ||
| 13 | </Wix> | ||
diff --git a/src/test/WixToolsetTest.CoreIntegration/TestData/Assembly/data/test.manifest b/src/test/WixToolsetTest.CoreIntegration/TestData/Assembly/data/test.manifest new file mode 100644 index 00000000..0da1f6d0 --- /dev/null +++ b/src/test/WixToolsetTest.CoreIntegration/TestData/Assembly/data/test.manifest | |||
| @@ -0,0 +1,76 @@ | |||
| 1 | <?xml version="1.0" encoding="utf-8"?> | ||
| 2 | <assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1"> | ||
| 3 | <assemblyIdentity version="1.0.0.0" name="MyApplication.app"/> | ||
| 4 | <trustInfo xmlns="urn:schemas-microsoft-com:asm.v2"> | ||
| 5 | <security> | ||
| 6 | <requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3"> | ||
| 7 | <!-- UAC Manifest Options | ||
| 8 | If you want to change the Windows User Account Control level replace the | ||
| 9 | requestedExecutionLevel node with one of the following. | ||
| 10 | |||
| 11 | <requestedExecutionLevel level="asInvoker" uiAccess="false" /> | ||
| 12 | <requestedExecutionLevel level="requireAdministrator" uiAccess="false" /> | ||
| 13 | <requestedExecutionLevel level="highestAvailable" uiAccess="false" /> | ||
| 14 | |||
| 15 | Specifying requestedExecutionLevel element will disable file and registry virtualization. | ||
| 16 | Remove this element if your application requires this virtualization for backwards | ||
| 17 | compatibility. | ||
| 18 | --> | ||
| 19 | <requestedExecutionLevel level="asInvoker" uiAccess="false" /> | ||
| 20 | </requestedPrivileges> | ||
| 21 | </security> | ||
| 22 | </trustInfo> | ||
| 23 | |||
| 24 | <compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1"> | ||
| 25 | <application> | ||
| 26 | <!-- A list of the Windows versions that this application has been tested on | ||
| 27 | and is designed to work with. Uncomment the appropriate elements | ||
| 28 | and Windows will automatically select the most compatible environment. --> | ||
| 29 | |||
| 30 | <!-- Windows Vista --> | ||
| 31 | <!--<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}" />--> | ||
| 32 | |||
| 33 | <!-- Windows 7 --> | ||
| 34 | <!--<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}" />--> | ||
| 35 | |||
| 36 | <!-- Windows 8 --> | ||
| 37 | <!--<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}" />--> | ||
| 38 | |||
| 39 | <!-- Windows 8.1 --> | ||
| 40 | <!--<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}" />--> | ||
| 41 | |||
| 42 | <!-- Windows 10 --> | ||
| 43 | <!--<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />--> | ||
| 44 | |||
| 45 | </application> | ||
| 46 | </compatibility> | ||
| 47 | |||
| 48 | <!-- Indicates that the application is DPI-aware and will not be automatically scaled by Windows at higher | ||
| 49 | DPIs. Windows Presentation Foundation (WPF) applications are automatically DPI-aware and do not need | ||
| 50 | to opt in. Windows Forms applications targeting .NET Framework 4.6 that opt into this setting, should | ||
| 51 | also set the 'EnableWindowsFormsHighDpiAutoResizing' setting to 'true' in their app.config. --> | ||
| 52 | <!-- | ||
| 53 | <application xmlns="urn:schemas-microsoft-com:asm.v3"> | ||
| 54 | <windowsSettings> | ||
| 55 | <dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true</dpiAware> | ||
| 56 | </windowsSettings> | ||
| 57 | </application> | ||
| 58 | --> | ||
| 59 | |||
| 60 | <!-- Enable themes for Windows common controls and dialogs (Windows XP and later) --> | ||
| 61 | <!-- | ||
| 62 | <dependency> | ||
| 63 | <dependentAssembly> | ||
| 64 | <assemblyIdentity | ||
| 65 | type="win32" | ||
| 66 | name="Microsoft.Windows.Common-Controls" | ||
| 67 | version="6.0.0.0" | ||
| 68 | processorArchitecture="*" | ||
| 69 | publicKeyToken="6595b64144ccf1df" | ||
| 70 | language="*" | ||
| 71 | /> | ||
| 72 | </dependentAssembly> | ||
| 73 | </dependency> | ||
| 74 | --> | ||
| 75 | |||
| 76 | </assembly> | ||
diff --git a/src/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj b/src/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj index e8eaf970..fce9b05b 100644 --- a/src/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj +++ b/src/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj | |||
| @@ -87,9 +87,11 @@ | |||
| 87 | <Content Include="TestData\ManualUpgrade\Package.wxs" CopyToOutputDirectory="PreserveNewest" /> | 87 | <Content Include="TestData\ManualUpgrade\Package.wxs" CopyToOutputDirectory="PreserveNewest" /> |
| 88 | <Content Include="TestData\ManualUpgrade\PackageComponents.wxs" CopyToOutputDirectory="PreserveNewest" /> | 88 | <Content Include="TestData\ManualUpgrade\PackageComponents.wxs" CopyToOutputDirectory="PreserveNewest" /> |
| 89 | <Content Include="TestData\Assembly\data\candle.exe" CopyToOutputDirectory="PreserveNewest" /> | 89 | <Content Include="TestData\Assembly\data\candle.exe" CopyToOutputDirectory="PreserveNewest" /> |
| 90 | <Content Include="TestData\Assembly\data\test.manifest" CopyToOutputDirectory="PreserveNewest" /> | ||
| 90 | <Content Include="TestData\Assembly\Package.en-us.wxl" CopyToOutputDirectory="PreserveNewest" /> | 91 | <Content Include="TestData\Assembly\Package.en-us.wxl" CopyToOutputDirectory="PreserveNewest" /> |
| 91 | <Content Include="TestData\Assembly\Package.wxs" CopyToOutputDirectory="PreserveNewest" /> | 92 | <Content Include="TestData\Assembly\Package.wxs" CopyToOutputDirectory="PreserveNewest" /> |
| 92 | <Content Include="TestData\Assembly\PackageComponents.wxs" CopyToOutputDirectory="PreserveNewest" /> | 93 | <Content Include="TestData\Assembly\PackageComponents.wxs" CopyToOutputDirectory="PreserveNewest" /> |
| 94 | <Content Include="TestData\Assembly\Win32Assembly.wxs" CopyToOutputDirectory="PreserveNewest" /> | ||
| 93 | <Content Include="TestData\Upgrade\DetectOnly.wxs" CopyToOutputDirectory="PreserveNewest" /> | 95 | <Content Include="TestData\Upgrade\DetectOnly.wxs" CopyToOutputDirectory="PreserveNewest" /> |
| 94 | <Content Include="TestData\Variables\data\test.txt" CopyToOutputDirectory="PreserveNewest" /> | 96 | <Content Include="TestData\Variables\data\test.txt" CopyToOutputDirectory="PreserveNewest" /> |
| 95 | <Content Include="TestData\Variables\Package.en-us.wxl" CopyToOutputDirectory="PreserveNewest" /> | 97 | <Content Include="TestData\Variables\Package.en-us.wxl" CopyToOutputDirectory="PreserveNewest" /> |
