Right click "Suppress" should be enabled even when the error list selection has some suppressed issues #6435
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Scenario: User bulk selects diagnostics in the error list for suppression/baselining, which includes at least one suppressible diagnostic, but still doesn't see any context menu item for suppressing the diagnostics.
Cause: Our current logic to show the Suppress/Remove suppression commands require that all the selected diagnostics are active/suppressed respectively. The design team has decided that we should loosen this check to "require that at least one of the selected diagnostics is active/suppressed respectively" - this decision was based on the feedback from few people dogfooding this feature.
Fix: Trivial fix to not account for the irrelevant diagnostics when deciding whether or not to show the command. The implementation of the command already drops all the irrelevant diagnostics.
Testing: Verified that we get the desired context menu visibility for mixed error list selection and invoking the commands also work as expected.
Fixes #6425