Skip to content

Commit

Permalink
clean up smoke tests project
Browse files Browse the repository at this point in the history
  • Loading branch information
smadala committed Oct 27, 2016
1 parent acee74f commit 822b11a
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 81 deletions.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"buildOptions": {
"delaySign": true,
"keyFile": "../../../scripts/key.snk",
"warningsAsErrors": true,
"additionalArguments": [ "/ruleset:../../../scripts/stylecop.test.ruleset", "/additionalFile:../../../scripts/stylecop.json" ]
},

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,29 +13,29 @@ namespace TestPlatform.TestUtilities
public class NumberOfProcessLaunchedUtility
{
/// <summary>
/// The number of process created.
/// To Find the process created by name during this task run
/// </summary>
/// <param name="cts">
/// The cts.
/// To cancel task
/// </param>
/// <param name="testhostProcessName">
/// The testhost process name.
/// <param name="processName">
/// Name of the process
/// </param>
/// <returns>
/// The <see cref="Task"/>.
/// </returns>
public static async Task<int> NumberOfProcessCreated(CancellationTokenSource cts, string testhostProcessName)
public static async Task<int> NumberOfProcessCreated(CancellationTokenSource cts, string processName)
{
var testhostProcessIDsBeforeRun = new List<int>();
var testhostProcessesBeforeRun = Process.GetProcessesByName(testhostProcessName);
var testhostProcessesBeforeRun = Process.GetProcessesByName(processName);

foreach (var process in testhostProcessesBeforeRun)
{
testhostProcessIDsBeforeRun.Add(process.Id);
}

var numOfProcessTask =
Task.Run(() => NumberOfProcessLaunchedDuringRun(cts.Token, testhostProcessIDsBeforeRun, testhostProcessName));
Task.Run(() => NumberOfProcessLaunchedDuringRun(cts.Token, testhostProcessIDsBeforeRun, processName));
return await numOfProcessTask;
}

Expand Down

0 comments on commit 822b11a

Please sign in to comment.