Add failing test for invalid command line switch.
Sean Hall committed
May 23, 2020 at 19:48 UTC
96e966ce322bc630afed6d0ca8c9ec68191c5f83
1 file changed
+29
src/test/WixToolsetTest.CoreIntegration/BundleFixture.cs
+29
@@ -174,6 +174,35 @@ namespace WixToolsetTest.CoreIntegration
174
}
175
}
176
177
+ [Fact(Skip = "Test demonstrates failure")]
178
+ public void CantBuildSingleExeBundleWithInvalidArgument()
179
+ {
180
+ var folder = TestData.Get(@"TestData");
181
+
182
+ using (var fs = new DisposableFileSystem())
183
+ {
184
+ var baseFolder = fs.GetFolder();
185
+ var intermediateFolder = Path.Combine(baseFolder, "obj");
186
+ var exePath = Path.Combine(baseFolder, @"bin\test.exe");
187
+
188
+ var result = WixRunner.Execute(new[]
189
+ {
190
+ "build",
191
+ Path.Combine(folder, "SingleExeBundle", "SingleExePackageGroup.wxs"),
192
+ Path.Combine(folder, "BundleWithPackageGroupRef", "Bundle.wxs"),
193
+ "-bindpath", Path.Combine(folder, "SimpleBundle", "data"),
194
+ "-bindpath", Path.Combine(folder, ".Data"),
195
+ "-intermediateFolder", intermediateFolder,
196
+ "-o", exePath,
197
+ "-nonexistentswitch", "param",
198
+ });
199
+
200
+ Assert.NotEqual(0, result.ExitCode);
201
+
202
+ Assert.False(File.Exists(exePath));
203
+ }
204
+ }
205
+
206
[Fact]
207
public void CanBuildSingleExeRemotePayloadBundle()
208
{