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

Better output for multiple (failing) tests with --as-cran #162

Merged
merged 2 commits into from
Sep 21, 2021

Conversation

gaborcsardi
Copy link
Member

Closes #161.

@hadley

OK, now the you get this with --as-cran:

─  checking examples ... NONE (505ms)
✔  checking for unstated dependencies in ‘tests’ ...
─  checking tests (490ms)
─  Running ‘a.R’ (523ms)
─  Running ‘b.R’ (491ms)
─  Running ‘c.R’ (532ms)
E  Some test files failed
   Running the tests in ‘tests/b.R’ failed.
   Complete output:
     > stop("error")
     Error: error
     Execution halted
✔  checking PDF version of manual (6.1s)

and this without --as-cran:

✔  checking for unstated dependencies in ‘tests’ ...
─  checking tests (454ms)
✔  Running ‘a.R’ (508ms)
E  Running ‘b.R’ (503ms)
   Running the tests in ‘tests/b.R’ failed.
   Complete output:
     > stop("error")
     Error: error
     Execution halted
✔  checking PDF version of manual (6.9s)

Ideally we would look at the .Rout and .Rout.fail files, and mark the failed test files in the --as-cran case as well, but that would need a bigger rewrite, because right now the output is based on the stdout + stderr of the check process only.

@codecov-commenter

This comment has been minimized.

Copy link
Member

@hadley hadley left a comment

Choose a reason for hiding this comment

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

Thanks for the fix!

@gaborcsardi gaborcsardi merged commit 279fa1b into master Sep 21, 2021
@gaborcsardi gaborcsardi deleted the fix/test-fail-as-cran branch September 21, 2021 16:51
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.

Parsing of test failures is slightly unclear
3 participants