diff --git a/Tasks/VsTestV2/nondistributedtest.ts b/Tasks/VsTestV2/nondistributedtest.ts index 6a411748e704..03f3c618019b 100644 --- a/Tasks/VsTestV2/nondistributedtest.ts +++ b/Tasks/VsTestV2/nondistributedtest.ts @@ -19,15 +19,17 @@ const runSettingsExt = '.runsettings'; const testSettingsExt = '.testsettings'; const sourceFilter = tl.getDelimitedInput('testAssemblyVer2', '\n', true); -const inputDataContract: InputDataContract = undefined; +let inputDataContract: InputDataContract = undefined; let testAssemblyFiles = undefined; -export function runNonDistributedTest() { +export function runNonDistributedTest(idc: InputDataContract) { try { console.log(tl.loc('runTestsLocally', 'vstest.console.exe')); console.log('========================================================'); + inputDataContract = idc; + testAssemblyFiles = getTestAssemblies(); if (!testAssemblyFiles || testAssemblyFiles.length === 0) { console.log('##vso[task.logissue type=warning;code=002004;]'); diff --git a/Tasks/VsTestV2/runvstest.ts b/Tasks/VsTestV2/runvstest.ts index 361415a6d8e6..48a8b97bd69a 100644 --- a/Tasks/VsTestV2/runvstest.ts +++ b/Tasks/VsTestV2/runvstest.ts @@ -54,7 +54,7 @@ if (osPlat !== 'win32') { if (inputDataContract.ExecutionSettings && inputDataContract.ExecutionSettings.RerunSettings && inputDataContract.ExecutionSettings.RerunSettings.RerunFailedTests) { - nondistributedtest.runNonDistributedTest(); + nondistributedtest.runNonDistributedTest(inputDataContract); } else { localtest.startTest(); } diff --git a/Tasks/VsTestV2/task.json b/Tasks/VsTestV2/task.json index 94dc227f3486..f91c712c4c95 100644 --- a/Tasks/VsTestV2/task.json +++ b/Tasks/VsTestV2/task.json @@ -17,7 +17,7 @@ "version": { "Major": 2, "Minor": 137, - "Patch": 3 + "Patch": 4 }, "demands": [ "vstest" diff --git a/Tasks/VsTestV2/task.loc.json b/Tasks/VsTestV2/task.loc.json index ae2d03147722..6b1354485833 100644 --- a/Tasks/VsTestV2/task.loc.json +++ b/Tasks/VsTestV2/task.loc.json @@ -17,7 +17,7 @@ "version": { "Major": 2, "Minor": 137, - "Patch": 3 + "Patch": 4 }, "demands": [ "vstest"