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

[VM] Coverage reports erroneously highlight @override #56645

Open
matanlurey opened this issue Sep 4, 2024 · 3 comments
Open

[VM] Coverage reports erroneously highlight @override #56645

matanlurey opened this issue Sep 4, 2024 · 3 comments
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. triaged Issue has been triaged by sub team type-bug Incorrect behavior (everything from a crash to more subtle misbehavior)

Comments

@matanlurey
Copy link
Contributor

I'm less sure how to describe this one, so I guess an example is in order:

      43            0 :   @override
      44              :   int get _mask {
      45              :     // coverage:ignore-start
      46              :     assert(false, 'Should not be called; file a bug report!');
      47              :     return key._mask;
      48              :     // coverage:ignore-end
      49              :   }
@dart-github-bot
Copy link
Collaborator

Summary: Coverage reports incorrectly include @override annotations in the coverage calculation, leading to inaccurate coverage metrics. This occurs when @override annotations are present on methods that are marked as unreachable using // coverage:ignore-start and // coverage:ignore-end.

@dart-github-bot dart-github-bot added area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. triage-automation See https://github.com/dart-lang/ecosystem/tree/main/pkgs/sdk_triage_bot. type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) labels Sep 4, 2024
@a-siva
Copy link
Contributor

a-siva commented Sep 4, 2024

@matanlurey if I understand correctly your question is why do we have coverage listed on line 43 instead of line 44 in the example above ?

@a-siva a-siva added triaged Issue has been triaged by sub team and removed triage-automation See https://github.com/dart-lang/ecosystem/tree/main/pkgs/sdk_triage_bot. labels Sep 4, 2024
@matanlurey
Copy link
Contributor Author

Right sorry, the title of this issue is bad. Renamed

@matanlurey matanlurey changed the title [VM] Coverage reports sometimes include @override annotations [VM] Coverage reports erroneously highlight @override Sep 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. triaged Issue has been triaged by sub team type-bug Incorrect behavior (everything from a crash to more subtle misbehavior)
Projects
None yet
Development

No branches or pull requests

3 participants