Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
eitsupi committed Jan 9, 2023
1 parent efe56d1 commit b0f93e3
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
9 changes: 9 additions & 0 deletions tests/testthat/_snaps/use_lintr.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# use_lintr add .lintr to .Rbuildignore for packages

Code
cat(brio::read_file(file.path(tmp_package_dir, ".Rbuildignore")))
Output
^lintr\.Rproj$
^\.Rproj\.user$
^\.lintr$

2 changes: 1 addition & 1 deletion tests/testthat/test-use_lintr.R
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,5 @@ test_that("use_lintr add .lintr to .Rbuildignore for packages", {
setwd(tmp_package_dir)
lintr_file <- use_lintr()
expect_true(file.exists(lintr_file))
expect_true("^\\.lintr$" %in% readLines(".Rbuildignore"))
expect_snapshot(cat(brio::read_file(file.path(tmp_package_dir, ".Rbuildignore"))))
})

0 comments on commit b0f93e3

Please sign in to comment.