test: Upgrade to xUnit v3 and mtp v2#681
Conversation
Summary of ChangesHello @benjiro, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request delivers a significant infrastructure upgrade by migrating the entire test suite to xUnit v3 and Microsoft.Testing.Platform v2. This modernization effort involves updating package dependencies, adjusting project configurations, and refactoring asynchronous test logic to incorporate cancellation tokens and optimized async return types. The changes aim to enhance the robustness, maintainability, and performance of the testing framework without altering existing test coverage. Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request successfully upgrades the test infrastructure to xUnit v3 and Microsoft.Testing.Platform v2. The changes are extensive and consistently applied across all test projects, including updating package versions, project files, and test code to use new APIs and propagate cancellation tokens. This is a solid modernization of the test suite. I have a couple of suggestions to improve test correctness and maintainability.
|
@benjiro are you still working on this task? The |
2192f42 to
3dbf7cc
Compare
3dbf7cc to
86799c1
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #681 +/- ##
==========================================
- Coverage 93.52% 93.08% -0.45%
==========================================
Files 69 65 -4
Lines 2981 2935 -46
Branches 355 355
==========================================
- Hits 2788 2732 -56
- Misses 135 140 +5
- Partials 58 63 +5 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
3d7842b to
3d1ef7f
Compare
6561390 to
193b7dd
Compare
|
Had to dust off my old windows box to debug the code coverage issue was a curly one. Seems that GithubActionLogger is interacting with Coverlet. Had to add Due to the upgrade to the MTP and coverage system there is a slight discrepancy overall code coverage |
askpt
left a comment
There was a problem hiding this comment.
Have a look into the package I referenced. I believe it can be removed. Other than that, LGTM!
Signed-off-by: Benjamin Evenson <2031163+benjiro@users.noreply.github.com>
193b7dd to
298db6c
Compare
This PR
This PR upgrades the test infrastructure to use xUnit v3 and Microsoft.Testing.Platform (mtp) v2, modernizing the testing framework across all test projects in the dotnet-sdk.
Related Issues
Fixes #624
Fixes #648
Notes
This is a significant infrastructure upgrade that affects all test projects:
OpenFeature.E2ETestsOpenFeature.Hosting.TestsOpenFeature.IntegrationTestsOpenFeature.Providers.MultiProvider.TestsOpenFeature.TestsThe changes include updates to test lifecycle management and assertion patterns to align with xUnit v3 conventions. Net reduction of ~40 lines of code across the test suite while maintaining all existing test coverage.
How to test
dotnet testto execute the full test suite