diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/WixToolsetTest.Bal/BalExtensionFixture.cs | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/test/WixToolsetTest.Bal/BalExtensionFixture.cs b/src/test/WixToolsetTest.Bal/BalExtensionFixture.cs index d93ed74a..97ac68a7 100644 --- a/src/test/WixToolsetTest.Bal/BalExtensionFixture.cs +++ b/src/test/WixToolsetTest.Bal/BalExtensionFixture.cs | |||
@@ -34,5 +34,33 @@ namespace WixToolsetTest.Bal | |||
34 | Assert.True(File.Exists(bundleFile)); | 34 | Assert.True(File.Exists(bundleFile)); |
35 | } | 35 | } |
36 | } | 36 | } |
37 | |||
38 | [Fact] | ||
39 | public void CantBuildUsingMBAWithNoPrereqs() | ||
40 | { | ||
41 | using (var fs = new DisposableFileSystem()) | ||
42 | { | ||
43 | var baseFolder = fs.GetFolder(); | ||
44 | var bundleFile = Path.Combine(baseFolder, "bin", "test.exe"); | ||
45 | var bundleSourceFolder = TestData.Get(@"TestData\MBA"); | ||
46 | var intermediateFolder = Path.Combine(baseFolder, "obj"); | ||
47 | |||
48 | var compileResult = WixRunner.Execute(new[] | ||
49 | { | ||
50 | "build", | ||
51 | Path.Combine(bundleSourceFolder, "Bundle.wxs"), | ||
52 | "-ext", TestData.Get(@"WixToolset.Bal.wixext.dll"), | ||
53 | "-ext", TestData.Get(@"WixToolset.NetFx.wixext.dll"), | ||
54 | "-intermediateFolder", intermediateFolder, | ||
55 | "-burnStub", TestData.Get(@"runtimes\win-x86\native\burn.x86.exe"), | ||
56 | "-o", bundleFile, | ||
57 | }); | ||
58 | Assert.Equal(6802, compileResult.ExitCode); | ||
59 | Assert.Equal("There must be at least one PrereqPackage when using the ManagedBootstrapperApplicationHost.\nThis is typically done by using the WixNetFxExtension and referencing one of the NetFxAsPrereq package groups.", compileResult.Messages[0].ToString()); | ||
60 | |||
61 | Assert.False(File.Exists(bundleFile)); | ||
62 | Assert.False(File.Exists(Path.Combine(intermediateFolder, "test.exe"))); | ||
63 | } | ||
64 | } | ||
37 | } | 65 | } |
38 | } | 66 | } |