diff --git a/.lintr b/.lintr index a998e05..262ef0d 100644 --- a/.lintr +++ b/.lintr @@ -1,4 +1,6 @@ -linters: with_defaults( +linters: linters_with_defaults( + indentation_linter = NULL, + object_length_linter = NULL, object_usage_linter = NULL, cyclocomp_linter = NULL ) diff --git a/R/data.R b/R/data.R index 5113db9..05b45d3 100644 --- a/R/data.R +++ b/R/data.R @@ -595,8 +595,9 @@ data_load_request <- function(path_data, hash = NULL, quiet = FALSE) { } else { stop("Invalid type for 'hash'") } - names(keys) <- vapply(keys, function(x) - bin2str(data_key_fingerprint(x$pub, version), ""), character(1)) + names(keys) <- vapply(keys, function(x) { + bin2str(data_key_fingerprint(x$pub, version), "") + }, character(1)) class(keys) <- "data_keys" attr(keys, "version") <- version } diff --git a/tests/testthat/test-util.R b/tests/testthat/test-util.R index bb3b16f..7143401 100644 --- a/tests/testthat/test-util.R +++ b/tests/testthat/test-util.R @@ -4,13 +4,16 @@ test_that("sys_which", { test_that("get_password_str", { testthat::with_mocked_bindings( - get_pass = function(prompt) - if (grepl("Verify", prompt)) "a" else "b", { - expect_error(get_password_str(TRUE, "password"), - "Passwords do not match") - expect_equal(get_password_str(FALSE, "password"), - "b") - }) + get_pass = function(prompt) { + if (grepl("Verify", prompt)) "a" else "b" + }, + { + expect_error(get_password_str(TRUE, "password"), + "Passwords do not match") + expect_equal(get_password_str(FALSE, "password"), + "b") + } + ) testthat::with_mocked_bindings( get_pass = function(prompt) "a", { diff --git a/tests/testthat/test-zzz-data.R b/tests/testthat/test-zzz-data.R index 55c5428..f760f0a 100644 --- a/tests/testthat/test-zzz-data.R +++ b/tests/testthat/test-zzz-data.R @@ -330,8 +330,9 @@ test_that("migrate", { keys_new <- data_admin_list_keys(path_data) reqs_new <- data_admin_list_requests(path_data) - map <- vapply(keys_old, function(k) - bin2str(data_key_fingerprint(k$pub, data_schema_version()), ""), "") + map <- vapply(keys_old, function(k) { + bin2str(data_key_fingerprint(k$pub, data_schema_version()), "") + }, "") expect_setequal(names(keys_new), unname(map)) v <- c("user", "host", "date", "pub", "key")