Running ‘testthat.R’ [4s/7s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(funrar)
  > 
  > test_check("funrar")
  ── 1. Error: Returned object is a matrix (@test-dist_matrix.R#9)  ──────────────
  invalid type character for column numbers 2
  Backtrace:
   1. testthat::expect_is(compute_dist_matrix(trait_df), "matrix")
   4. funrar::compute_dist_matrix(trait_df)
   6. cluster::daisy(traits_table, metric = metric)
  
  ── 2. Error: Names in distance matrix named after rownames (@test-dist_matrix.R#
  invalid type character for column numbers 1
  Backtrace:
   1. testthat::expect_warning(compute_dist_matrix(trait))
   6. funrar::compute_dist_matrix(trait)
   8. cluster::daisy(traits_table, metric = metric)
  
  ── 3. Error: Distance matrix contains good values (@test-dist_matrix.R#40)  ────
  invalid type character for column numbers 1
  Backtrace:
   1. funrar::compute_dist_matrix(trait)
   3. cluster::daisy(traits_table, metric = metric)
  
  ── 4. Error: (unknown) (@test-distinctiveness.R#38)  ───────────────────────────
  invalid type character for column numbers 1
  Backtrace:
   1. funrar::compute_dist_matrix(trait_df)
   3. cluster::daisy(traits_table, metric = metric)
  
  ── 5. Error: (unknown) (@test-distinctiveness_range.R#38)  ─────────────────────
  invalid type character for column numbers 1
  Backtrace:
   1. funrar::compute_dist_matrix(trait_df)
   3. cluster::daisy(traits_table, metric = metric)
  
  ── 6. Error: (unknown) (@test-funrar.R#40)  ────────────────────────────────────
  invalid type character for column numbers 1
  Backtrace:
   1. funrar::compute_dist_matrix(trait_df)
   3. cluster::daisy(traits_table, metric = metric)
  
  ── 7. Error: (unknown) (@test-scarcity.R#31)  ──────────────────────────────────
  invalid type character for column numbers 1
  Backtrace:
   1. funrar::compute_dist_matrix(trait_df)
   3. cluster::daisy(traits_table, metric = metric)
  
  ── 8. Failure: Conversion from sparse & dense matrices to tidy data.frame (@test
  ...[] not equivalent to `com_df`.
  Component "site": target is character, current is factor
  Component "species": target is character, current is factor
  
  ── 9. Failure: Conversion from sparse & dense matrices to tidy data.frame (@test
  matrix_to_stack(abund_sparse, value_col = "val") not equivalent to `abund_df`.
  Component "site": target is character, current is factor
  Component "species": target is character, current is factor
  
  ── 10. Error: (unknown) (@test-uniqueness.R#31)  ───────────────────────────────
  invalid type character for column numbers 1
  Backtrace:
   1. funrar::compute_dist_matrix(trait_df)
   3. cluster::daisy(traits_table, metric = metric)
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  [ OK: 154 | SKIPPED: 0 | WARNINGS: 0 | FAILED: 10 ]
  1.  Error: Returned object is a matrix (@test-dist_matrix.R#9) 
  2.  Error: Names in distance matrix named after rownames (@test-dist_matrix.R#19) 
  3.  Error: Distance matrix contains good values (@test-dist_matrix.R#40) 
  4.  Error: (unknown) (@test-distinctiveness.R#38) 
  5.  Error: (unknown) (@test-distinctiveness_range.R#38) 
  6.  Error: (unknown) (@test-funrar.R#40) 
  7.  Error: (unknown) (@test-scarcity.R#31) 
  8.  Failure: Conversion from sparse & dense matrices to tidy data.frame (@test-tidy_matrix.R#112) 
  9.  Failure: Conversion from sparse & dense matrices to tidy data.frame (@test-tidy_matrix.R#115) 
  10. Error: (unknown) (@test-uniqueness.R#31) 
  
  Error: testthat unit tests failed
  Execution halted