@joebigelow / wix-1 / commits / 1eb00ae9

Fix Heat tests and run BuildTask tests.

Sean Hall committed Mar 31, 2021 at 11:35 UTC 1eb00ae94855f10612aa79cf669e0c73cf75fa93
2 files changed +7 -5
appveyor.cmd
+2
@@ -12,6 +12,8 @@ nuget restore || exit /b
12 msbuild -p:Configuration=%_C% || exit /b
13
14 :: Test
15 +dotnet test -c %_C% --no-build src\test\WixToolsetTest.BuildTasks || exit /b
16 +
17 dotnet publish -c %_C% -o %_P%\dotnet-wix\ -f netcoreapp2.1 src\wix || exit /b
18
19 dotnet publish -c %_C% -o %_P%\WixToolset.Sdk\separate\net461\x86\buildtasks\ -f net461 -r win-x86 src\WixToolset.BuildTasks || exit /b
src/test/WixToolsetTest.Sdk/MsbuildHeatFixture.cs
+5 -5
@@ -66,7 +66,7 @@ namespace WixToolsetTest.Sdk
66 var section = intermediate.Sections.Single();
67
68 var fileSymbol = section.Symbols.OfType<FileSymbol>().Single();
69 - Assert.Equal(@"SourceDir\HeatFilePackage.wixproj", fileSymbol[FileSymbolFields.Source].PreviousValue.AsPath().Path);
69 + Assert.Equal(@"SourceDir\HeatFilePackage.wixproj", fileSymbol[FileSymbolFields.Source].PreviousValue.AsPath()?.Path);
70 }
71 }
72
@@ -142,8 +142,8 @@ namespace WixToolsetTest.Sdk
142 var section = intermediate.Sections.Single();
143
144 var fileSymbols = section.Symbols.OfType<FileSymbol>().ToArray();
145 - Assert.Equal(@"SourceDir\MyProgram.txt", fileSymbols[0][FileSymbolFields.Source].PreviousValue.AsPath().Path);
146 - Assert.Equal(@"SourceDir\MyProgram.json", fileSymbols[1][FileSymbolFields.Source].PreviousValue.AsPath().Path);
145 + Assert.Equal(@"SourceDir\MyProgram.txt", fileSymbols[0][FileSymbolFields.Source].PreviousValue.AsPath()?.Path);
146 + Assert.Equal(@"SourceDir\MyProgram.json", fileSymbols[1][FileSymbolFields.Source].PreviousValue.AsPath()?.Path);
147 }
148 }
149
@@ -253,7 +253,7 @@ namespace WixToolsetTest.Sdk
253 var section = intermediate.Sections.Single();
254
255 var fileSymbol = section.Symbols.OfType<FileSymbol>().Single();
256 - Assert.Equal(Path.Combine(fs.BaseFolder, "ToolsVersion4Cs", "bin", "Release\\\\ToolsVersion4Cs.dll"), fileSymbol[FileSymbolFields.Source].PreviousValue.AsPath().Path);
256 + Assert.Equal(Path.Combine(fs.BaseFolder, "ToolsVersion4Cs", "bin", "Release\\\\ToolsVersion4Cs.dll"), fileSymbol[FileSymbolFields.Source].AsPath()?.Path);
257 }
258 }
259
@@ -368,7 +368,7 @@ namespace WixToolsetTest.Sdk
368 var section = intermediate.Sections.Single();
369
370 var fileSymbol = section.Symbols.OfType<FileSymbol>().Single();
371 - Assert.Equal(Path.Combine(fs.BaseFolder, "SdkStyleCs", "bin", "Release", "netstandard2.0\\\\SdkStyleCs.dll"), fileSymbol[FileSymbolFields.Source].PreviousValue.AsPath().Path);
371 + Assert.Equal(Path.Combine(fs.BaseFolder, "SdkStyleCs", "bin", "Release", "netstandard2.0\\\\SdkStyleCs.dll"), fileSymbol[FileSymbolFields.Source].AsPath()?.Path);
372 }
373 }
374 }