diff options
author | Rob Mensching <rob@firegiant.com> | 2017-11-01 10:59:45 -0700 |
---|---|---|
committer | Rob Mensching <rob@firegiant.com> | 2017-11-01 10:59:45 -0700 |
commit | 2bb37beda887d120a0ddabf874ad25357101faa1 (patch) | |
tree | c35e97b03274b86cfc9ff7fd2caeee211165a140 /src/test | |
parent | df7413aeed3aea3425dff20ae0c8b1be3a3ab525 (diff) | |
download | wix-2bb37beda887d120a0ddabf874ad25357101faa1.tar.gz wix-2bb37beda887d120a0ddabf874ad25357101faa1.tar.bz2 wix-2bb37beda887d120a0ddabf874ad25357101faa1.zip |
Update to WiX Intermediate Representation
Diffstat (limited to 'src/test')
-rw-r--r-- | src/test/WixToolsetTest.CoreIntegrationFixture/ProgramFixture.cs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/test/WixToolsetTest.CoreIntegrationFixture/ProgramFixture.cs b/src/test/WixToolsetTest.CoreIntegrationFixture/ProgramFixture.cs index daa3da42..46d15ed8 100644 --- a/src/test/WixToolsetTest.CoreIntegrationFixture/ProgramFixture.cs +++ b/src/test/WixToolsetTest.CoreIntegrationFixture/ProgramFixture.cs | |||
@@ -3,7 +3,10 @@ | |||
3 | namespace WixToolsetTest.CoreIntegrationFixture | 3 | namespace WixToolsetTest.CoreIntegrationFixture |
4 | { | 4 | { |
5 | using System.IO; | 5 | using System.IO; |
6 | using System.Linq; | ||
6 | using WixToolset.Core; | 7 | using WixToolset.Core; |
8 | using WixToolset.Data; | ||
9 | using WixToolset.Data.Tuples; | ||
7 | using WixToolsetTest.CoreIntegrationFixture.Utility; | 10 | using WixToolsetTest.CoreIntegrationFixture.Utility; |
8 | using Xunit; | 11 | using Xunit; |
9 | 12 | ||
@@ -23,9 +26,18 @@ namespace WixToolsetTest.CoreIntegrationFixture | |||
23 | var result = program.Run(new WixToolsetServiceProvider(), new[] { "build", "Package.wxs", "PackageComponents.wxs", "-loc", "Package.en-us.wxl", "-bindpath", "data", "-intermediateFolder", intermediateFolder, "-o", $@"{intermediateFolder}\bin\test.msi" }); | 26 | var result = program.Run(new WixToolsetServiceProvider(), new[] { "build", "Package.wxs", "PackageComponents.wxs", "-loc", "Package.en-us.wxl", "-bindpath", "data", "-intermediateFolder", intermediateFolder, "-o", $@"{intermediateFolder}\bin\test.msi" }); |
24 | 27 | ||
25 | Assert.Equal(0, result); | 28 | Assert.Equal(0, result); |
29 | #if FIXED_MSI_BACKEND | ||
26 | Assert.True(File.Exists(Path.Combine(intermediateFolder, @"bin\test.msi"))); | 30 | Assert.True(File.Exists(Path.Combine(intermediateFolder, @"bin\test.msi"))); |
27 | Assert.True(File.Exists(Path.Combine(intermediateFolder, @"bin\test.wixpdb"))); | 31 | Assert.True(File.Exists(Path.Combine(intermediateFolder, @"bin\test.wixpdb"))); |
28 | Assert.True(File.Exists(Path.Combine(intermediateFolder, @"bin\MsiPackage\test.txt"))); | 32 | Assert.True(File.Exists(Path.Combine(intermediateFolder, @"bin\MsiPackage\test.txt"))); |
33 | #else | ||
34 | var intermediate = Intermediate.Load(Path.Combine(intermediateFolder, @"bin\test.msi")); | ||
35 | Assert.Single(intermediate.Sections); | ||
36 | |||
37 | var wixFile = intermediate.Sections.SelectMany(s => s.Tuples).OfType<WixFileTuple>().Single(); | ||
38 | Assert.Equal(@"data\test.txt", wixFile[WixFileTupleFields.Source].AsPath().Path); | ||
39 | Assert.Equal(@"test.txt", wixFile[WixFileTupleFields.Source].PreviousValue.AsPath().Path); | ||
40 | #endif | ||
29 | } | 41 | } |
30 | } | 42 | } |
31 | } | 43 | } |