Running 'testthat.R' [5s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > library(testthat)
  > library(topr)
  > 
  > test_check("topr")
  [ FAIL 6 | WARN 0 | SKIP 4 | PASS 5 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • empty test (4)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Failure ('test-locuszoom.R:2'): locuszoom works ─────────────────────────────
  Expected `locuszoom(R2_CD_UKBB, gene = "IL23R")` to run without any errors.
  i Actually got a <rlang_error>:
    Error in `dplyr::rename_with()`:
    ! `.fn` must return a vector of length 0, not 1.
  ── Failure ('test-manhattan.R:2'): basic manhattan works ───────────────────────
  `manhattan(CD_UKBB)` threw an unexpected error.
  Message: `.fn` must return a vector of length 0, not 1.
  Class:   rlang_error/error/condition
  Backtrace:
       ▆
    1. ├─testthat::expect_error(manhattan(CD_UKBB), NA) at test-manhattan.R:2:2
    2. │ └─testthat:::expect_condition_matching(...)
    3. │   └─testthat:::quasi_capture(...)
    4. │     ├─testthat (local) .capture(...)
    5. │     │ └─base::withCallingHandlers(...)
    6. │     └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    7. ├─topr::manhattan(CD_UKBB)
    8. │ └─topr:::dat_check(df, verbose = verbose)
    9. │   ├─... %>% dat_chr_check()
   10. │   └─topr:::dat_column_check_and_set(dat, verbose = verbose, locuszoomplot = locuszoomplot)
   11. │     └─... %>% ...
   12. ├─topr:::dat_chr_check(.)
   13. ├─dplyr::rename_with(., ~"ALT", matches(c("^alt$"), ignore.case = TRUE))
   14. ├─dplyr::rename_with(., ~"REF", matches(c("^ref$"), ignore.case = TRUE))
   15. ├─dplyr::rename_with(., ~"BETA", matches(c("^beta$"), ignore.case = TRUE))
   16. ├─dplyr::rename_with(...)
   17. ├─dplyr::rename_with(...)
   18. ├─dplyr::rename_with(...)
   19. ├─dplyr::rename_with(...)
   20. └─dplyr:::rename_with.data.frame(., ~"ID", matches(c("^rsid$", "^rsname$", "^snp$"), ignore.case = TRUE))
   21.   └─cli::cli_abort("{.arg .fn} must return a vector of length {length(sel)}, not {length(new)}.")
   22.     └─rlang::abort(...)
  ── Failure ('test-manhattan.R:7'): adcvanced manhattan works ───────────────────
  Expected `manhattan(CD_UKBB)` to run without any errors.
  i Actually got a <rlang_error>:
    Error in `dplyr::rename_with()`:
    ! `.fn` must return a vector of length 0, not 1.
  ── Failure ('test-regionplot.R:2'): basic regionplot works ─────────────────────
  `regionplot(CD_UKBB, gene = "IL23R")` threw an unexpected error.
  Message: `.fn` must return a vector of length 0, not 1.
  Class:   rlang_error/error/condition
  Backtrace:
       ▆
    1. ├─testthat::expect_error(regionplot(CD_UKBB, gene = "IL23R"), NA) at test-regionplot.R:2:2
    2. │ └─testthat:::expect_condition_matching(...)
    3. │   └─testthat:::quasi_capture(...)
    4. │     ├─testthat (local) .capture(...)
    5. │     │ └─base::withCallingHandlers(...)
    6. │     └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    7. ├─topr::regionplot(CD_UKBB, gene = "IL23R")
    8. │ ├─... %>% ...
    9. │ └─topr:::dat_check(df, verbose = verbose, locuszoomplot = locuszoomplot)
   10. │   ├─... %>% dat_chr_check()
   11. │   └─topr:::dat_column_check_and_set(dat, verbose = verbose, locuszoomplot = locuszoomplot)
   12. │     └─... %>% ...
   13. ├─topr:::set_size_shape_alpha(., size, shape, alpha, locuszoomplot = locuszoomplot)
   14. │ └─topr:::set_size(df, size, locuszoomplot = locuszoomplot)
   15. ├─topr:::set_log10p(., ntop)
   16. ├─topr:::dat_chr_check(.)
   17. ├─dplyr::rename_with(., ~"ALT", matches(c("^alt$"), ignore.case = TRUE))
   18. ├─dplyr::rename_with(., ~"REF", matches(c("^ref$"), ignore.case = TRUE))
   19. ├─dplyr::rename_with(., ~"BETA", matches(c("^beta$"), ignore.case = TRUE))
   20. ├─dplyr::rename_with(...)
   21. ├─dplyr::rename_with(...)
   22. ├─dplyr::rename_with(...)
   23. ├─dplyr::rename_with(...)
   24. └─dplyr:::rename_with.data.frame(., ~"ID", matches(c("^rsid$", "^rsname$", "^snp$"), ignore.case = TRUE))
   25.   └─cli::cli_abort("{.arg .fn} must return a vector of length {length(sel)}, not {length(new)}.")
   26.     └─rlang::abort(...)
  ── Failure ('test-regionplot.R:6'): advanecd regionplot works ──────────────────
  Expected `regionplot(CD_UKBB, gene = "IL23R")` to run without any errors.
  i Actually got a <rlang_error>:
    Error in `dplyr::rename_with()`:
    ! `.fn` must return a vector of length 0, not 1.
  ── Error ('test-utils.R:2'): get_lead_snps works ───────────────────────────────
  Error in `dplyr::rename_with(., ~"ID", matches(c("^rsid$", "^rsname$", 
      "^snp$"), ignore.case = TRUE))`: `.fn` must return a vector of length 0, not 1.
  Backtrace:
       ▆
    1. ├─topr::get_lead_snps(CD_UKBB) at test-utils.R:2:2
    2. │ └─topr:::dat_check(dat, verbose = verbose)
    3. │   ├─... %>% dat_chr_check()
    4. │   └─topr:::dat_column_check_and_set(dat, verbose = verbose, locuszoomplot = locuszoomplot)
    5. │     └─... %>% ...
    6. ├─topr:::dat_chr_check(.)
    7. ├─dplyr::rename_with(., ~"ALT", matches(c("^alt$"), ignore.case = TRUE))
    8. ├─dplyr::rename_with(., ~"REF", matches(c("^ref$"), ignore.case = TRUE))
    9. ├─dplyr::rename_with(., ~"BETA", matches(c("^beta$"), ignore.case = TRUE))
   10. ├─dplyr::rename_with(...)
   11. ├─dplyr::rename_with(...)
   12. ├─dplyr::rename_with(...)
   13. ├─dplyr::rename_with(...)
   14. └─dplyr:::rename_with.data.frame(., ~"ID", matches(c("^rsid$", "^rsname$", "^snp$"), ignore.case = TRUE))
   15.   └─cli::cli_abort("{.arg .fn} must return a vector of length {length(sel)}, not {length(new)}.")
   16.     └─rlang::abort(...)
  
  [ FAIL 6 | WARN 0 | SKIP 4 | PASS 5 ]
  Error: Test failures
  Execution halted