From bd3ee565f342bc0bb015594f303d13b67285a958 Mon Sep 17 00:00:00 2001 From: Sean Hall Date: Thu, 23 Apr 2020 12:17:32 +1000 Subject: Update ManagedHost tests to run off of a bundle. --- src/test/WixToolsetTest.ManagedHost/TestEngine.cs | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'src/test/WixToolsetTest.ManagedHost/TestEngine.cs') diff --git a/src/test/WixToolsetTest.ManagedHost/TestEngine.cs b/src/test/WixToolsetTest.ManagedHost/TestEngine.cs index 4dd531ad..751ed59c 100644 --- a/src/test/WixToolsetTest.ManagedHost/TestEngine.cs +++ b/src/test/WixToolsetTest.ManagedHost/TestEngine.cs @@ -4,15 +4,26 @@ namespace WixToolsetTest.ManagedHost { using System.Collections.Generic; using System.Diagnostics; + using System.IO; using WixBuildTools.TestSupport; + using WixToolset.Core.TestPackage; public class TestEngine { private static readonly string TestEngineFile = TestData.Get(@"..\Win32\examples\Example.TestEngine\Example.TestEngine.exe"); + public static readonly string BurnStubFile = TestData.Get(@"runtimes\win-x86\native\burn.x86.exe"); - public TestEngineResult RunShutdownEngine(string baFile) + public TestEngineResult RunShutdownEngine(string bundleFilePath, string tempFolderPath) { - var args = new string[] { '"' + baFile + '"' }; + var baFolderPath = Path.Combine(tempFolderPath, "ba"); + var extractFolderPath = Path.Combine(tempFolderPath, "extract"); + var extractResult = BundleExtractor.ExtractBAContainer(null, bundleFilePath, baFolderPath, extractFolderPath); + extractResult.AssertSuccess(); + + var args = new string[] { + '"' + bundleFilePath + '"', + '"' + extractResult.GetBAFilePath(baFolderPath) + '"', + }; return RunProcessCaptureOutput(TestEngineFile, args); } -- cgit v1.2.3-55-g6feb