diff options
Diffstat (limited to 'src/ext/Bal/test/WixToolsetTest.BootstrapperApplications/BalExtensionFixture.cs')
| -rw-r--r-- | src/ext/Bal/test/WixToolsetTest.BootstrapperApplications/BalExtensionFixture.cs | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/src/ext/Bal/test/WixToolsetTest.BootstrapperApplications/BalExtensionFixture.cs b/src/ext/Bal/test/WixToolsetTest.BootstrapperApplications/BalExtensionFixture.cs index 07d3dacb..576e7c6c 100644 --- a/src/ext/Bal/test/WixToolsetTest.BootstrapperApplications/BalExtensionFixture.cs +++ b/src/ext/Bal/test/WixToolsetTest.BootstrapperApplications/BalExtensionFixture.cs | |||
| @@ -56,6 +56,44 @@ namespace WixToolsetTest.BootstrapperApplications | |||
| 56 | } | 56 | } |
| 57 | 57 | ||
| 58 | [TestMethod] | 58 | [TestMethod] |
| 59 | public void CanBuildUsingDisplayFilesInUseDialogCondition() | ||
| 60 | { | ||
| 61 | using (var fs = new DisposableFileSystem()) | ||
| 62 | { | ||
| 63 | var baseFolder = fs.GetFolder(); | ||
| 64 | var bundleFile = Path.Combine(baseFolder, "bin", "test.exe"); | ||
| 65 | var bundleSourceFolder = TestData.Get(@"TestData\WixStdBa"); | ||
| 66 | var intermediateFolder = Path.Combine(baseFolder, "obj"); | ||
| 67 | var baFolderPath = Path.Combine(baseFolder, "ba"); | ||
| 68 | var extractFolderPath = Path.Combine(baseFolder, "extract"); | ||
| 69 | |||
| 70 | var compileResult = WixRunner.Execute(new[] | ||
| 71 | { | ||
| 72 | "build", | ||
| 73 | Path.Combine(bundleSourceFolder, "DisplayFilesInUseDialogConditionBundle.wxs"), | ||
| 74 | "-ext", TestData.Get(@"WixToolset.BootstrapperApplications.wixext.dll"), | ||
| 75 | "-intermediateFolder", intermediateFolder, | ||
| 76 | "-bindpath", Path.Combine(bundleSourceFolder, "data"), | ||
| 77 | "-o", bundleFile, | ||
| 78 | }); | ||
| 79 | compileResult.AssertSuccess(); | ||
| 80 | |||
| 81 | Assert.IsTrue(File.Exists(bundleFile)); | ||
| 82 | |||
| 83 | var extractResult = BundleExtractor.ExtractBAContainer(null, bundleFile, baFolderPath, extractFolderPath); | ||
| 84 | extractResult.AssertSuccess(); | ||
| 85 | |||
| 86 | var balPackageInfos = extractResult.GetBADataTestXmlLines("/ba:BootstrapperApplicationData/ba:WixBalPackageInfo"); | ||
| 87 | WixAssert.CompareLineByLine(new string[] | ||
| 88 | { | ||
| 89 | "<WixBalPackageInfo PackageId='test.msi' DisplayFilesInUseDialogCondition='1' />", | ||
| 90 | }, balPackageInfos); | ||
| 91 | |||
| 92 | Assert.IsTrue(File.Exists(Path.Combine(baFolderPath, "thm.wxl"))); | ||
| 93 | } | ||
| 94 | } | ||
| 95 | |||
| 96 | [TestMethod] | ||
| 59 | public void CanBuildUsingBootstrapperApplicationId() | 97 | public void CanBuildUsingBootstrapperApplicationId() |
| 60 | { | 98 | { |
| 61 | using (var fs = new DisposableFileSystem()) | 99 | using (var fs = new DisposableFileSystem()) |
| @@ -298,6 +336,7 @@ namespace WixToolsetTest.BootstrapperApplications | |||
| 298 | { | 336 | { |
| 299 | "bal:Condition/@Condition contains the built-in Variable 'WixBundleAction', which is not available when it is evaluated. (Unavailable Variables are: 'WixBundleAction'.). Rewrite the condition to avoid Variables that are never valid during its evaluation.", | 337 | "bal:Condition/@Condition contains the built-in Variable 'WixBundleAction', which is not available when it is evaluated. (Unavailable Variables are: 'WixBundleAction'.). Rewrite the condition to avoid Variables that are never valid during its evaluation.", |
| 300 | "Overridable variable 'TEST1' collides with 'Test1' with Bundle/@CommandLineVariables value 'caseInsensitive'.", | 338 | "Overridable variable 'TEST1' collides with 'Test1' with Bundle/@CommandLineVariables value 'caseInsensitive'.", |
| 339 | "The *Package/@bal:DisplayFilesInUseDialogCondition attribute's value '=' is not a valid bundle condition.", | ||
| 301 | "The *Package/@bal:DisplayInternalUICondition attribute's value '=' is not a valid bundle condition.", | 340 | "The *Package/@bal:DisplayInternalUICondition attribute's value '=' is not a valid bundle condition.", |
| 302 | "The location of the Variable related to the previous error.", | 341 | "The location of the Variable related to the previous error.", |
| 303 | }, messages.ToArray()); | 342 | }, messages.ToArray()); |
