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

Add warnings are errors option #731

Closed
michaellevy opened this issue Mar 16, 2018 · 1 comment
Closed

Add warnings are errors option #731

michaellevy opened this issue Mar 16, 2018 · 1 comment
Labels
feature a feature request or enhancement

Comments

@michaellevy
Copy link

From @jimhester here:

What you would likely want to do is modify https://github.com/r-lib/testthat/blob/master/R/reporter-check.R to additionally tally expectation_warning and then stop for warnings in a similar way to how it stops for errors.

But maybe at this point it would be better to open an issue in the testthat repository and we can consider adding a stop_for_warning option to the check reporter.

@jimhester
Copy link
Member

As of #721 you can now set options(warn = 2) to change warnings into errors in your tests, which would then fail the build if desired. So I am going to close this for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature a feature request or enhancement
Projects
None yet
Development

No branches or pull requests

2 participants