Assert diagnostics pass correct number of arguments#59419
Conversation
|
I appreciate the thought, but this would not have helped uncover the linked issue, so I'm not sure this has much value from an ENC standpoint. I guess someone from @dotnet/roslyn-compiler might have a different opinion? |
|
@davidwengier I'm surprised the assertion didn't fail for ENC0088. I'll try to take a look and understand why. |
That diagnostic is only reported when an unknown error happens. We don't have tests for unknown errors, because if we knew what the error was we'd fix it :) |
|
I thought this test is "faking" the unexpected exception via the roslyn/src/EditorFeatures/CSharpTest/EditAndContinue/ActiveStatementTests.cs Lines 11228 to 11230 in 02a5659 |
|
Well now I'm confused.. if we had a test for that scenario, then why is it passing at all, given the bug? I will have to dig in more |
|
@Youssef1313 I updated #59443 to validate all EnC diagnostics. Do you think there is still value in this PR for general compiler scenarios? |
|
@davidwengier I think it will be beneficial, not only for compiler messages, but also IDExxxx. I'll have to make sure this actually fails for both scenarios. |
Compiler part was already done in #60925. This PR is now about analyzers. |
…dateFormatStringDiagnosticAnalyzer.cs Co-authored-by: CyrusNajmabadi <cyrus.najmabadi@gmail.com>
There was a problem hiding this comment.
Please wait on merging this. I think this won't detect everything because of the early return for Fixed in cfd414c. Waiting on CI to see if there are additional failures._messageArgs.Length == 0.
Related to #59418