Skip to content
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

Listen to build manager events to know when build is complete #64366

Merged
merged 9 commits into from
Oct 3, 2022

Conversation

JoeRobich
Copy link
Member

Fixes CSharpBuild.BuildProject integration test when running against IntPreview builds of VS.

// The build summary line should be second to last in the output window
return lines[^2].Extent.GetText();
// Find the build summary line
for (var index = lines.Count - 1; index > 0; index--)
Copy link
Member Author

Choose a reason for hiding this comment

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

Found that this was returning "Elapsed time" instead of the build summary.

@JoeRobich
Copy link
Member Author

@jasonmalinowski This is ready for another review. I believe Shen is taking care of the newly failing integration tests in another PR.

@JoeRobich JoeRobich mentioned this pull request Oct 3, 2022
for (var index = lines.Count - 1; index >= 0; index--)
{
var lineText = lines[index].Extent.GetText();
if (lineText.StartsWith("========== Build:"))
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
if (lineText.StartsWith("========== Build:"))
if (lineText.StartsWith("=========="))

Since that won't depend on localization anymore.

Copy link
Member Author

Choose a reason for hiding this comment

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

I agree, but the reality is that every test that uses this method immediately Asserts the returned string equals an English build summary. Probably long term we should capture the success, failed, and canceled values returned by the UpdateSolutionEvents Done and return those instead of the build summary.

@JoeRobich JoeRobich merged commit 9ff40aa into dotnet:main Oct 3, 2022
@ghost ghost added this to the Next milestone Oct 3, 2022
@RikkiGibson RikkiGibson modified the milestones: Next, 17.5 P1 Oct 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants