diff options
author | Sean Hall <r.sean.hall@gmail.com> | 2020-08-02 08:32:54 -0600 |
---|---|---|
committer | Sean Hall <r.sean.hall@gmail.com> | 2020-08-09 10:37:12 -0600 |
commit | d26157531381aba81d2cac15e424b7e5c738253a (patch) | |
tree | 5bd5793ec90529c4be397e9034f17e35b7c9e4a2 /src/test/WixToolsetTest.CoreIntegration | |
parent | 581897da13bd8a20eea0c2079262caaa06cde676 (diff) | |
download | wix-d26157531381aba81d2cac15e424b7e5c738253a.tar.gz wix-d26157531381aba81d2cac15e424b7e5c738253a.tar.bz2 wix-d26157531381aba81d2cac15e424b7e5c738253a.zip |
WIXFEAT:4763 Change "string" variable type to literal and add "formatted".
Diffstat (limited to 'src/test/WixToolsetTest.CoreIntegration')
3 files changed, 31 insertions, 0 deletions
diff --git a/src/test/WixToolsetTest.CoreIntegration/BadInputFixture.cs b/src/test/WixToolsetTest.CoreIntegration/BadInputFixture.cs index d6c7b091..7a630a36 100644 --- a/src/test/WixToolsetTest.CoreIntegration/BadInputFixture.cs +++ b/src/test/WixToolsetTest.CoreIntegration/BadInputFixture.cs | |||
@@ -32,5 +32,28 @@ namespace WixToolsetTest.CoreIntegration | |||
32 | Assert.InRange(result.ExitCode, 2, Int32.MaxValue); | 32 | Assert.InRange(result.ExitCode, 2, Int32.MaxValue); |
33 | } | 33 | } |
34 | } | 34 | } |
35 | |||
36 | [Fact] | ||
37 | public void BundleVariableWithBadTypeIsRejected() | ||
38 | { | ||
39 | var folder = TestData.Get(@"TestData\BadInput"); | ||
40 | |||
41 | using (var fs = new DisposableFileSystem()) | ||
42 | { | ||
43 | var baseFolder = fs.GetFolder(); | ||
44 | var intermediateFolder = Path.Combine(baseFolder, "obj"); | ||
45 | var wixlibPath = Path.Combine(intermediateFolder, @"test.wixlib"); | ||
46 | |||
47 | var result = WixRunner.Execute(new[] | ||
48 | { | ||
49 | "build", | ||
50 | Path.Combine(folder, "BundleVariable.wxs"), | ||
51 | "-intermediateFolder", intermediateFolder, | ||
52 | "-o", wixlibPath, | ||
53 | }); | ||
54 | |||
55 | Assert.Equal(21, result.ExitCode); | ||
56 | } | ||
57 | } | ||
35 | } | 58 | } |
36 | } | 59 | } |
diff --git a/src/test/WixToolsetTest.CoreIntegration/TestData/BadInput/BundleVariable.wxs b/src/test/WixToolsetTest.CoreIntegration/TestData/BadInput/BundleVariable.wxs new file mode 100644 index 00000000..293b379f --- /dev/null +++ b/src/test/WixToolsetTest.CoreIntegration/TestData/BadInput/BundleVariable.wxs | |||
@@ -0,0 +1,7 @@ | |||
1 | <?xml version="1.0" encoding="utf-8" ?> | ||
2 | <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs" | ||
3 | xmlns:ex="http://www.example.com/scheams/v1/wxs"> | ||
4 | <Fragment> | ||
5 | <Variable Name="BadType" Type="doesnotexist" Value="dne" /> | ||
6 | </Fragment> | ||
7 | </Wix> | ||
diff --git a/src/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj b/src/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj index 601a66e7..f4aab391 100644 --- a/src/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj +++ b/src/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj | |||
@@ -22,6 +22,7 @@ | |||
22 | <Content Include="TestData\AppSearch\NestedDirSearchUnderRegSearch.msi" CopyToOutputDirectory="PreserveNewest" /> | 22 | <Content Include="TestData\AppSearch\NestedDirSearchUnderRegSearch.msi" CopyToOutputDirectory="PreserveNewest" /> |
23 | <Content Include="TestData\AppSearch\RegistrySearch.wxs" CopyToOutputDirectory="PreserveNewest" /> | 23 | <Content Include="TestData\AppSearch\RegistrySearch.wxs" CopyToOutputDirectory="PreserveNewest" /> |
24 | <Content Include="TestData\BadEnsureTable\BadEnsureTable.wxs" CopyToOutputDirectory="PreserveNewest" /> | 24 | <Content Include="TestData\BadEnsureTable\BadEnsureTable.wxs" CopyToOutputDirectory="PreserveNewest" /> |
25 | <Content Include="TestData\BadInput\BundleVariable.wxs" CopyToOutputDirectory="PreserveNewest" /> | ||
25 | <Content Include="TestData\BadInput\RegistryKey.wxs" CopyToOutputDirectory="PreserveNewest" /> | 26 | <Content Include="TestData\BadInput\RegistryKey.wxs" CopyToOutputDirectory="PreserveNewest" /> |
26 | <Content Include="TestData\BindVariables\DefaultedVariable.wxs" CopyToOutputDirectory="PreserveNewest" /> | 27 | <Content Include="TestData\BindVariables\DefaultedVariable.wxs" CopyToOutputDirectory="PreserveNewest" /> |
27 | <Content Include="TestData\BindVariables\data\test.txt" CopyToOutputDirectory="PreserveNewest" /> | 28 | <Content Include="TestData\BindVariables\data\test.txt" CopyToOutputDirectory="PreserveNewest" /> |