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

fix: print test results while running coverage #7743

Merged
merged 1 commit into from
Apr 20, 2024

Conversation

klkvr
Copy link
Member

@klkvr klkvr commented Apr 20, 2024

Motivation

Currently forge coverage does not print any data if tests are failing. This is not really great UX if tests are running for long time and might result in coverage generating incomplete/empty reports without any feedback.

Solution

include TesetArgs into CoverageArgs and invoke run_tests on it.


// Add hit data to the coverage report
let data = rx.into_iter().flat_map(|(_, suite)| {
let data = outcome.results.into_iter().flat_map(|(_, suite)| {
Copy link
Member

Choose a reason for hiding this comment

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

Note that this is now not ran in parallel with test execution, but that's probably fine.

Copy link
Member

Choose a reason for hiding this comment

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

should be fine

Copy link
Member

@mattsse mattsse left a comment

Choose a reason for hiding this comment

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

nice!


// Add hit data to the coverage report
let data = rx.into_iter().flat_map(|(_, suite)| {
let data = outcome.results.into_iter().flat_map(|(_, suite)| {
Copy link
Member

Choose a reason for hiding this comment

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

should be fine

@mattsse mattsse merged commit 63fff35 into master Apr 20, 2024
19 checks passed
@mattsse mattsse deleted the klkvr/coverage-print-test-results branch April 20, 2024 23:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants