-
-
Notifications
You must be signed in to change notification settings - Fork 14.7k
annotate-snippet emitter: Add UI test where annotated_files count is > 1 #64205
Copy link
Copy link
Closed
Closed
Copy link
Labels
A-diagnosticsArea: Messages for errors, warnings, and lintsArea: Messages for errors, warnings, and lintsC-enhancementCategory: An issue proposing an enhancement or a PR with one.Category: An issue proposing an enhancement or a PR with one.E-help-wantedCall for participation: Help is requested to fix this issue.Call for participation: Help is requested to fix this issue.E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
A-diagnosticsArea: Messages for errors, warnings, and lintsArea: Messages for errors, warnings, and lintsC-enhancementCategory: An issue proposing an enhancement or a PR with one.Category: An issue proposing an enhancement or a PR with one.E-help-wantedCall for participation: Help is requested to fix this issue.Call for participation: Help is requested to fix this issue.E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Part of #59346
It would be nice to have a UI test for the annotate-snippet emitter, that includes annotations that span multiple files. The goal of this issue is to find and add such a test.
Instructions
A simple way to look for this, would be to add this code:
to the top of
fn slices_for_filesand then check the failing UI tests.If there are failing UI tests, it means that those UI tests include a diagnostic that probably spans multiple files.
The next step, is to copy that file (and possible auxiliary files) over into
src/test/ui/annotate-snippet/and add// compile-flags: --error-format human-annotate-rsto the top of the UI test.Once that's done, be sure to run the added test and open a PR including the blessed stderr files.