Comments (1)
Do you have any thoughts on the best way for this function to report failure? Maybe just print the lints object first and say it failed? Example implementation.
expect_lint_free <- function(...) {
lints <- lint_package(...)
has_lints <- length(lints) > 0
if (has_lints) {
print(lints)
}
expectation(!has_lints, "not lint free", "lint free")
}
Only issue I see with this approach is maybe it wouldn't work well with some of the Non-default testthat reporters, but admittedly I don't have much experience using them.
from lintr.
Related Issues (20)
- Revert inline rawNamespace usage
- Is it possible to exclude individual linters on directory (not file) level? HOT 2
- [new lint] Empty first line in roxy examples HOT 1
- No visible global function definition for '%>%' HOT 3
- Adding new line character removes effect HOT 3
- Requesting less indent of what should be in list long assignment HOT 6
- Error from `.lintr.R` configuration when invoked via R Studio addin (but not console)
- CRAN failures on R-devel HOT 1
- Patch release lintr 3.1.2
- docs: return() is not undesirable HOT 2
- Styler and lintr disagree on what happens after a linebreak HOT 2
- undesirable_function_linter(unnamed_vector_of_functions) should "just work" HOT 2
- Make `{withr}` a runtime dependency of `{lintr}`? HOT 3
- Add coverage tests for make_linter_from_function_xpath
- Is there any way to skip the checking of glue syntax in name injection? HOT 3
- Unrecognized R6 class HOT 4
- object_name_linter warning with R6 class HOT 1
- Lint `return()` usage with pipe in `return_linter()`? HOT 4
- indentation_linter reports "startColumn": 0 -> invalid SARIF file HOT 3
- Are roxy checks across different locales working in GHA?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lintr.