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

Update GivenThatWeWantMSBuildToRespectCustomCulture.cs #47549

Merged
merged 1 commit into from
Mar 13, 2025

Conversation

ViktorHofer
Copy link
Member

@ViktorHofer ViktorHofer commented Mar 13, 2025

Fixes failing SupportRespectAlreadyAssignedItemCulture_IsNotSupported_BuildShouldFail test by consolidating back with the core only test theory.

This is causing all PRs in sdk main to fail because of a machine rollout that updated VS to 17.13.x yesterday.

Fixes failing `SupportRespectAlreadyAssignedItemCulture_IsNotSupported_BuildShouldFail` test by consolidating back with the core only test theory.

This is causing all PRs in sdk main to fail because of a machine rollout that updated VS to 17.13.x
@Copilot Copilot bot review requested due to automatic review settings March 13, 2025 14:16
@dotnet-issue-labeler dotnet-issue-labeler bot added Area-NetSDK untriaged Request triage from a team member labels Mar 13, 2025

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 fixes the failing test by consolidating the behavior into a single test method that verifies a warning instead of a build failure when custom culture issues occur.

  • Added a [Theory] attribute to the warning test.
  • Removed the failing test and its associated commentary, streamlining the test behavior.
Comments suppressed due to low confidence (1)

test/Microsoft.NET.Build.Tests/GivenThatWeWantMSBuildToRespectCustomCulture.cs:46

  • Removing the failing test reduces coverage for scenarios where the build should fail due to custom culture issues. Consider adding alternative tests to ensure that incorrect custom culture settings are properly handled.
public void SupportRespectAlreadyAssignedItemCulture_IsNotSupported_BuildShouldFail(string targetFramework)
@ViktorHofer ViktorHofer requested a review from marcpopMSFT March 13, 2025 14:17
@ViktorHofer
Copy link
Member Author

Force merge to unblock CI in sdk. The failure is unrelated and the VMR legs don't exercise this code path.

@ViktorHofer ViktorHofer merged commit c74c63b into main Mar 13, 2025
32 of 40 checks passed
@ViktorHofer ViktorHofer deleted the ViktorHofer-patch-2 branch March 13, 2025 15:51
@edvilme
Copy link
Member

edvilme commented Mar 13, 2025

/backport to release/9.0.1xx

Copy link
Contributor

Started backporting to release/9.0.1xx: https://github.com/dotnet/sdk/actions/runs/13839056126

Copy link
Contributor

@edvilme backporting to "release/9.0.1xx" failed, the patch most likely resulted in conflicts:

$ git am --3way --empty=keep --ignore-whitespace --keep-non-patch changes.patch

Applying: Update GivenThatWeWantMSBuildToRespectCustomCulture.cs
Using index info to reconstruct a base tree...
M	test/Microsoft.NET.Build.Tests/GivenThatWeWantMSBuildToRespectCustomCulture.cs
Falling back to patching base and 3-way merge...
Auto-merging test/Microsoft.NET.Build.Tests/GivenThatWeWantMSBuildToRespectCustomCulture.cs
CONFLICT (content): Merge conflict in test/Microsoft.NET.Build.Tests/GivenThatWeWantMSBuildToRespectCustomCulture.cs
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
hint: When you have resolved this problem, run "git am --continue".
hint: If you prefer to skip this patch, run "git am --skip" instead.
hint: To restore the original branch and stop patching, run "git am --abort".
hint: Disable this message with "git config set advice.mergeConflict false"
Patch failed at 0001 Update GivenThatWeWantMSBuildToRespectCustomCulture.cs
Error: The process '/usr/bin/git' failed with exit code 128

Please backport manually!

@edvilme
Copy link
Member

edvilme commented Mar 13, 2025

/backport to release/9.0.2xx

Copy link
Contributor

Started backporting to release/9.0.2xx: https://github.com/dotnet/sdk/actions/runs/13839085981

@edvilme
Copy link
Member

edvilme commented Mar 13, 2025

/backport to release/9.0.3xx

Copy link
Contributor

Started backporting to release/9.0.3xx: https://github.com/dotnet/sdk/actions/runs/13839552149

@edvilme
Copy link
Member

edvilme commented Mar 13, 2025

/backport to release/10.0.1xx-preview2

Copy link
Contributor

Started backporting to release/10.0.1xx-preview2: https://github.com/dotnet/sdk/actions/runs/13839601837

@nagilson
Copy link
Member

9.0.100 failed, so I would recommend doing that manually

@Forgind
Copy link
Member

Forgind commented Mar 13, 2025

9.0.100 failed, so I would recommend doing that manually

edvilme clarified that 9.0.100 doesn't have this issue; it was just a typo

@edvilme
Copy link
Member

edvilme commented Mar 13, 2025

9.0.100 failed, so I would recommend doing that manually

edvilme clarified that 9.0.100 doesn't have this issue; it was just a typo

Update: Just discovered that 9.0.1xx does have the issue, although just one of the tests in this pr exists, I will create a new pr deleting the failing test SupportRespectAlreadyAssignedItemCulture_IsNotSupported_BuildShouldFail

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-NetSDK untriaged Request triage from a team member
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants