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

Use Roslyn Source Generator Testing SDK to test interop source generators #84867

Merged
merged 19 commits into from May 8, 2023

Conversation

jkoritzinsky
Copy link
Member

This lets us more directly test the UX for the diagnostics we emit from the interop source generators.

Opening in draft form now as I've only moved over the LibraryImportGenerator tests (and I need to move over the ComInterfaceGenerator tests as well due to some changes in common files for defining code snippets)

Contributes to #84441

@jkoritzinsky jkoritzinsky added area-System.Runtime.InteropServices test-enhancement Improvements of test source code source-generator Indicates an issue with a source generator feature labels Apr 14, 2023
@ghost ghost assigned jkoritzinsky Apr 14, 2023
@ghost
Copy link

ghost commented Apr 14, 2023

Tagging subscribers to this area: @dotnet/interop-contrib
See info in area-owners.md if you want to be subscribed.

Issue Details

This lets us more directly test the UX for the diagnostics we emit from the interop source generators.

Opening in draft form now as I've only moved over the LibraryImportGenerator tests (and I need to move over the ComInterfaceGenerator tests as well due to some changes in common files for defining code snippets)

Contributes to #84441

Author: jkoritzinsky
Assignees: -
Labels:

area-System.Runtime.InteropServices, test-enhancement, source-generator

Milestone: -

@jkoritzinsky jkoritzinsky requested review from AaronRobinsonMSFT and elinor-fung and removed request for AaronRobinsonMSFT April 21, 2023 18:53
Copy link
Member

@AaronRobinsonMSFT AaronRobinsonMSFT left a comment

Choose a reason for hiding this comment

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

I'm fine with anything that aligns with official product support for source generators. I skimmed the code, but if it is green consider me signed off. I assume you didn't add/remove any tests. I would at least do a rough compare for test count.

@jkoritzinsky
Copy link
Member Author

I converted one test at a time and validated that we didn't lose any tests in the conversion.

Failures are unrelated, so I'll merge this in.

@jkoritzinsky jkoritzinsky merged commit fc1cb19 into dotnet:main May 8, 2023
173 of 178 checks passed
@jkoritzinsky jkoritzinsky deleted the diagnostic-test-improvements branch May 8, 2023 19:03
@ghost ghost locked as resolved and limited conversation to collaborators Jun 8, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-System.Runtime.InteropServices source-generator Indicates an issue with a source generator feature test-enhancement Improvements of test source code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants