Skip to content

Enable binlog capture for BuildWithComponents31 test - #54863

Merged
MichaelSimons merged 2 commits into
mainfrom
michaelsimons/enable-binlog-rz10007-test
Jun 25, 2026
Merged

MichaelSimons merged 2 commits into
mainfrom
michaelsimons/enable-binlog-rz10007-test

Conversation

@MichaelSimons

@MichaelSimons MichaelSimons commented Jun 18, 2026 •

Copy link
Copy Markdown
Member

Summary

Add diagnostic information for an intermittently failing test by switching from build.Execute() to ExecuteCommand(build), which automatically captures a binlog. Set WithWorkingDirectory to the test asset's sandbox directory so the binlog is placed there rather than the shared test runner's current working directory.

Context

This test is intermittently failing in CI on macOS arm64 with:

NavMenu.razor(1,5): error RZ10007: The attribute 'class' is used two or more times for this element

Related to #54826

@MichaelSimons
MichaelSimons requested review from a team and Copilot June 18, 2026 13:06
@MichaelSimons
MichaelSimons requested a review from a team June 18, 2026 13:08

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR updates a Razor integration test to run MSBuild via the AspNetSdkTest.ExecuteCommand() helper so MSBuild binlogs are captured automatically, improving diagnosability of intermittent CI failures related to legacy Razor compilation.

Changes:

  • Switch BuildWithComponents31IntegrationTest from direct BuildCommand.Execute() to ExecuteCommand(build) to enable automatic /bl: binlog capture.

Comment on lines 16 to +17
var build = new BuildCommand(projectDirectory);
build.Execute().Should().Pass();
ExecuteCommand(build).Should().Pass();
@MichaelSimons
MichaelSimons force-pushed the michaelsimons/enable-binlog-rz10007-test branch from 3f49ddf to c7522e7 Compare June 18, 2026 13:14
Use ExecuteCommand() instead of direct Execute() so the base class
adds /bl:msbuild0.binlog automatically. This will provide diagnostic
data when the intermittent RZ10007 false positive occurs in CI.

Relates to #54826

Co-authored-by: Copilot <[email protected]>
@MichaelSimons
MichaelSimons force-pushed the michaelsimons/enable-binlog-rz10007-test branch from c7522e7 to d045afd Compare June 18, 2026 18:06

@davidwengier davidwengier left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Approval does not imply acceptance of ownership of any of this code 😛

@MichaelSimons
MichaelSimons merged commit 185cd51 into main Jun 25, 2026
25 checks passed
@MichaelSimons
MichaelSimons deleted the michaelsimons/enable-binlog-rz10007-test branch June 25, 2026 15:40
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 11.0-preview7 milestone Jun 29, 2026
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