Running ‘testthat.R’ [89s/134s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(egor)
  Loading required package: dplyr
  
  Attaching package: 'dplyr'
  
  The following object is masked from 'package:testthat':
  
      matches
  
  The following objects are masked from 'package:stats':
  
      filter, lag
  
  The following objects are masked from 'package:base':
  
      intersect, setdiff, setequal, union
  
  Loading required package: tibble
  > library(dplyr)
  > 
  > test_check("egor")
  5 Egos/ Ego Networks 
  88 Alters 
  Min. Netsize 12 
  Average Netsize 17.6 
  Max. Netsize 23 
  Average Density 0.469722755505364 
  
  Ego sampling design:
  Independent Sampling design (with replacement)
  Called via srvyr
  Sampling variables:
   - ids: `1`
   - weights: sampling_weight
  Data variables: .egoID (dbl), sex (chr), age (fct), age.years (int), country
    (chr), income (dbl), sampling_weight (dbl), avg_nts (dbl)
  Alter survey design:
    Maximum nominations: Inf 
  5 Egos/ Ego Networks 
  88 Alters 
  Min. Netsize 12 
  Average Netsize 17.6 
  Max. Netsize 23 
  Average Density 0.469722755505364 
  
  Ego sampling design:
  Independent Sampling design (with replacement)
  Called via srvyr
  Sampling variables:
   - ids: `1`
   - weights: sampling_weight
  Data variables: .egoID (dbl), sex (chr), age (fct), age.years (int), country
    (chr), income (dbl), sampling_weight (dbl), avg_nts (dbl)
  Alter survey design:
    Maximum nominations: Inf 
  3 Egos/ Ego Networks 
  33 Alters 
  Min. Netsize 7 
  Average Netsize 11 
  Max. Netsize 17 
  Average Density 0.465219421101774 
  Alter survey design:
    Maximum nominations: Inf 
  6 Egos/ Ego Networks 
  35 Alters 
  Min. Netsize 4 
  Average Netsize 5.83333333333333 
  Max. Netsize 8 
  Average Density 0.456349206349206 
  Alter survey design:
    Maximum nominations: Inf 
  5 Egos/ Ego Networks 
  16 Alters 
  Min. Netsize 4 
  Average Netsize 4 
  Max. Netsize 4 
  Average Density 1.33333333333333 
  Alter survey design:
    Maximum nominations: Inf 
  4 Egos/ Ego Networks 
  16 Alters 
  Min. Netsize 4 
  Average Netsize 4 
  Max. Netsize 4 
  Average Density 1.33333333333333 
  Alter survey design:
    Maximum nominations: Inf 
  Sorting data by egoID: Transforming alters data to long format: Transforming wide dyad data to edgelist: Filtering out empty alter entries using provided network size values: Sorting data by egoID: Transforming alters data to long format: Transforming wide dyad data to edgelist: Filtering out empty alter entries using provided network size values: Sorting data by egoID: Transforming alters data to long format: Transforming wide dyad data to edgelist: Sorting data by egoID: Transforming alters data to long format: Transforming wide dyad data to edgelist: Filtering out empty alter entries using provided network size values: Sorting data by egoID: Transforming alters data to long format: Transforming wide dyad data to edgelist: Sorting data by egoID: Transforming alters data to long format: Transforming wide dyad data to edgelist: Filtering out empty alter entries using provided network size values: Sorting data by egoID: Transforming alters data to long format: Transforming wide dyad data to edgelist: ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Failure (test-conversions.R:5:13): as_tibble and other conversions work ─────
  `{ ... }` threw an error.
  Message: Problem with `mutate()` column `from`.
  ℹ `from = as.character(...)`.
  ✖ invalid 'labels'; length 0 should be 1 or 2
  Class:   dplyr:::mutate_error/dplyr_error/rlang_error/error/condition
  Backtrace:
       █
    1. ├─testthat::expect_error(...) test-conversions.R:5:12
    2. │ └─testthat:::quasi_capture(...)
    3. │   ├─testthat:::.capture(...)
    4. │   │ └─base::withCallingHandlers(...)
    5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    6. ├─egor::as_network(e) test-conversions.R:8:14
    7. │ └─base::mapply(FUN = network.data.frame, x$.aaties, x$.alts, SIMPLIFY = FALSE)
    8. │   └─(function (aaties, alts) ...
    9. │     └─`%>%`(...)
   10. ├─dplyr::select(., -V1, -V2)
   11. ├─dplyr::left_join(., aaties, by = c(from = ".srcID", to = ".tgtID"))
   12. ├─dplyr::mutate(...)
   13. ├─dplyr:::mutate.data.frame(...)
   14. │ └─dplyr:::mutate_cols(.data, ..., caller_env = caller_env())
   15. │   ├─base::withCallingHandlers(...)
   16. │   └─mask$eval_all_mutate(quo)
   17. ├─base::factor(...)
   18. │ └─base::stop(...)
   19. └─base::.handleSimpleError(...)
   20.   └─dplyr:::h(simpleError(msg, call))
  ── Failure (test-plot_egor.R:9:3): plot plots egor objects ─────────────────────
  `{ ... }` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
       █
    1. ├─testthat::expect_error(...) test-plot_egor.R:9:2
    2. │ └─testthat:::quasi_capture(...)
    3. │   ├─testthat:::.capture(...)
    4. │   │ └─base::withCallingHandlers(...)
    5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    6. ├─base::plot(...) test-plot_egor.R:44:4
    7. └─egor:::plot.egor(...)
    8.   └─egor::plot_egor(x, ...)
    9.     └─egor::plot_egograms(...)
   10.       └─egor:::plot_egogram(...)
   11.         └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   12.           └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:59:3): plot_egograms works with minimal arguments ──
  `{ ... }` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:59:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...) test-plot_egor.R:61:4
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:99:3): plot_egograms doesn't fail on empty alters or aaties ──
  `plot_egograms(x = e, venn_var = "sex", pie_var = "country", show_venn_labels = TRUE)` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:99:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...)
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:110:3): plot_egograms doesn't fail on empty alters or aaties ──
  `plot_egograms(x = e, venn_var = "sex", pie_var = "country", show_venn_labels = TRUE)` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:110:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...)
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:120:3): plot_egograms plots with and without venn labels ──
  `{ ... }` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:120:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...) test-plot_egor.R:122:4
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:139:13): plotting works when active data level is not ego ──
  `{ ... }` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:139:12
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...) test-plot_egor.R:143:14
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:182:3): plot_ego_gram adjusts node size according to venn count ──
  `{ ... }` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:182:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(x = e, ego_no = 2, venn_var = "sex", pie_var = "country") test-plot_egor.R:185:4
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:216:3): plot_ego_gram works with edge arguments ───
  `{ ... }` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:216:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...) test-plot_egor.R:219:4
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:242:3): plot_ego_gram works without pie_var/venn_var ──
  `{ ... }` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:242:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...) test-plot_egor.R:245:4
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Error (test-plot_egor.R:269:3): plot_ego_gram works without pie_var/venn_var ──
  Error: invalid RGB specification
  Backtrace:
      █
   1. ├─testthat::expect_warning(...) test-plot_egor.R:269:2
   2. │ └─testthat:::quasi_capture(enquo(object), label, capture_warnings)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...) test-plot_egor.R:270:4
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:286:13): plot_ego_gram plots empty levels of a factor variables for pies and venns ──
  `{ ... }` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:286:12
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...) test-plot_egor.R:295:14
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Error (test-plot_egor.R:334:13): plot_ego_gram plots empty levels of a factor variables for pies and venns ──
  Error: invalid RGB specification
  Backtrace:
      █
   1. ├─testthat::expect_warning(...) test-plot_egor.R:334:12
   2. │ └─testthat:::quasi_capture(enquo(object), label, capture_warnings)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...) test-plot_egor.R:335:14
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:370:13): egograms with many venns produce adequatly sized nodes ──
  `plot_egograms(...)` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:370:12
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...)
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:383:3): egograms with `include_ego = TRUE` work properly ──
  `plot_egograms(...)` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:383:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...)
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:388:3): egograms with `include_ego = TRUE` work properly ──
  `plot_egograms(...)` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:388:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...)
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Error (test-plot_egor.R:396:3): egograms with reverse ordered alters plot correctly ──
  Error: invalid RGB specification
  Backtrace:
      █
   1. └─egor::plot_egograms(egor32, venn_var = "age", pie_var = "country") test-plot_egor.R:396:2
   2.   └─egor:::plot_egogram(...)
   3.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   4.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Error (test-plot_egor.R:448:3): plot_egograms removes and warns for alters with missing data in pie/venn_var ──
  Error: invalid RGB specification
  Backtrace:
      █
   1. ├─testthat::expect_warning(...) test-plot_egor.R:448:2
   2. │ └─testthat:::quasi_capture(enquo(object), label, capture_warnings)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(t1, 1, venn_var = "country", pie_var = "test")
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:456:3): plot_egograms() argument ascending_inwards works ──
  `plot_egograms(e1, 1, venn_var = "age", pie_var = "sex", ascending_inwards = FALSE)` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:456:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...)
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  ── Failure (test-plot_egor.R:457:3): plot_egograms() argument ascending_inwards works ──
  `plot_egograms(e1, 1, venn_var = "age", pie_var = "sex", ascending_inwards = TRUE)` threw an error.
  Message: invalid RGB specification
  Class:   simpleError/error/condition
  Backtrace:
      █
   1. ├─testthat::expect_error(...) test-plot_egor.R:457:2
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat:::.capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─egor::plot_egograms(...)
   7.   └─egor:::plot_egogram(...)
   8.     └─egor:::ring(0, 0, radi[i + 1], radi[i], col = cols[i], border = "grey70")
   9.       └─graphics::polygon(top, border = NA, col = col, ...)
  
  [ FAIL 20 | WARN 0 | SKIP 0 | PASS 197 ]
  Error: Test failures
  Execution halted