Skip to content

Port https://github.com/aspnet/AspNetCore/pull/12879 to 3.1 #14638

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 1, 2019

Conversation

ryanbrandenburg
Copy link
Contributor

Fixes #13925.

using var testResult = await ProcessEx.RunViaShellAsync(Output, clientAppSubdirPath, "npm run test");
Assert.True(0 == testResult.ExitCode, ErrorMessages.GetFailedProcessMessage("npm run test", Project, testResult));
}
var testcommand = "npm run test" + template == "angular" ? "-- --watch=false" : "";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know why this conditional argument is needed. Can you add a comment?

@@ -104,14 +104,14 @@ public static ProcessEx Run(ITestOutputHelper output, string workingDirectory, s
return new ProcessEx(output, proc);
}

public static async Task<ProcessEx> RunViaShellAsync(ITestOutputHelper output, string workingDirectory, string commandAndArgs)
public static ProcessEx RunViaShell(ITestOutputHelper output, string workingDirectory, string commandAndArgs)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why no longer async?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

await result.Exited was the last async thing in this function, without it we get that annoying warning/error about an async with nothing awaited. Unfortunately I wasn't able to find/manufacture an overload to wait for result to complete that was both async and did a timeout.

@mkArtakMSFT mkArtakMSFT merged commit 8e6cd2c into release/3.1-preview1 Oct 1, 2019
@mkArtakMSFT mkArtakMSFT deleted the rybrande/AngularStylesPreview1 branch October 1, 2019 22:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants