diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/WixToolsetTest.Bal/BalExtensionFixture.cs | 36 |
1 files changed, 34 insertions, 2 deletions
diff --git a/src/test/WixToolsetTest.Bal/BalExtensionFixture.cs b/src/test/WixToolsetTest.Bal/BalExtensionFixture.cs index a19013f5..277a941a 100644 --- a/src/test/WixToolsetTest.Bal/BalExtensionFixture.cs +++ b/src/test/WixToolsetTest.Bal/BalExtensionFixture.cs | |||
@@ -46,6 +46,39 @@ namespace WixToolsetTest.Bal | |||
46 | } | 46 | } |
47 | 47 | ||
48 | [Fact] | 48 | [Fact] |
49 | public void CanBuildUsingOverridable() | ||
50 | { | ||
51 | using (var fs = new DisposableFileSystem()) | ||
52 | { | ||
53 | var baseFolder = fs.GetFolder(); | ||
54 | var bundleFile = Path.Combine(baseFolder, "bin", "test.exe"); | ||
55 | var bundleSourceFolder = TestData.Get(@"TestData\Overridable"); | ||
56 | var intermediateFolder = Path.Combine(baseFolder, "obj"); | ||
57 | var baFolderPath = Path.Combine(baseFolder, "ba"); | ||
58 | var extractFolderPath = Path.Combine(baseFolder, "extract"); | ||
59 | |||
60 | var compileResult = WixRunner.Execute(new[] | ||
61 | { | ||
62 | "build", | ||
63 | Path.Combine(bundleSourceFolder, "Bundle.wxs"), | ||
64 | "-ext", TestData.Get(@"WixToolset.Bal.wixext.dll"), | ||
65 | "-intermediateFolder", intermediateFolder, | ||
66 | "-o", bundleFile, | ||
67 | }); | ||
68 | compileResult.AssertSuccess(); | ||
69 | |||
70 | Assert.True(File.Exists(bundleFile)); | ||
71 | |||
72 | var extractResult = BundleExtractor.ExtractBAContainer(null, bundleFile, baFolderPath, extractFolderPath); | ||
73 | extractResult.AssertSuccess(); | ||
74 | |||
75 | var balOverridableVariables = extractResult.SelectBADataNodes("/ba:BootstrapperApplicationData/ba:WixStdbaOverridableVariable"); | ||
76 | var balOverridableVariable = (XmlNode)Assert.Single(balOverridableVariables); | ||
77 | Assert.Equal("<WixStdbaOverridableVariable Name='Test1' />", balOverridableVariable.GetTestXml()); | ||
78 | } | ||
79 | } | ||
80 | |||
81 | [Fact] | ||
49 | public void CanBuildUsingWixStdBa() | 82 | public void CanBuildUsingWixStdBa() |
50 | { | 83 | { |
51 | using (var fs = new DisposableFileSystem()) | 84 | using (var fs = new DisposableFileSystem()) |
@@ -69,7 +102,7 @@ namespace WixToolsetTest.Bal | |||
69 | } | 102 | } |
70 | } | 103 | } |
71 | 104 | ||
72 | [Fact(Skip = "Skip test until cycle with Netfx.wixext and this repo is resolved")] | 105 | [Fact] |
73 | public void CantBuildUsingMBAWithNoPrereqs() | 106 | public void CantBuildUsingMBAWithNoPrereqs() |
74 | { | 107 | { |
75 | using (var fs = new DisposableFileSystem()) | 108 | using (var fs = new DisposableFileSystem()) |
@@ -84,7 +117,6 @@ namespace WixToolsetTest.Bal | |||
84 | "build", | 117 | "build", |
85 | Path.Combine(bundleSourceFolder, "Bundle.wxs"), | 118 | Path.Combine(bundleSourceFolder, "Bundle.wxs"), |
86 | "-ext", TestData.Get(@"WixToolset.Bal.wixext.dll"), | 119 | "-ext", TestData.Get(@"WixToolset.Bal.wixext.dll"), |
87 | "-ext", TestData.Get(@"WixToolset.NetFx.wixext.dll"), | ||
88 | "-intermediateFolder", intermediateFolder, | 120 | "-intermediateFolder", intermediateFolder, |
89 | "-o", bundleFile, | 121 | "-o", bundleFile, |
90 | }); | 122 | }); |