Running ‘testthat.R’ [7s/24s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(SynthCast)
  > data("df_example")
  > 
  > test_check("SynthCast")
  [1] "Error in Function prepare_dataset():"
  <error/rlang_error>
  Error in `select()`:
  ! Can't convert an integer to a symbol.
  ---
  Backtrace:
    1. SynthCast::prepare_dataset(...)
         at test-syth-cast.R:18:0
   28. rlang::sym(all_of(col_unit_name))
  [1] "Error in Function compute_synthetic_control():"
  <simpleError in UseMethod("distinct"): no applicable method for 'distinct' applied to an object of class "c('rlang_error', 'error', 'condition')">
  [1] "Error in Function compute_result_tables():"
  <simpleError in round(synth.res$solution.v, round.digit): non-numeric argument to mathematical function>
  [1] "Forecasting Unit:  30 . Serie:  x1"
  [1] "Error in Function prepare_dataset():"
  <error/rlang_error>
  Error in `select()`:
  ! Can't convert an integer to a symbol.
  ---
  Backtrace:
    1. SynthCast::run_synthetic_forecast(...)
         at test-syth-cast.R:46:0
   33. rlang::sym(all_of(col_unit_name))
  [1] "Error in Function compute_synthetic_control():"
  <simpleError in UseMethod("distinct"): no applicable method for 'distinct' applied to an object of class "c('rlang_error', 'error', 'condition')">
  [1] "Error in Function compute_result_tables():"
  <simpleError in round(synth.res$solution.v, round.digit): non-numeric argument to mathematical function>
  [ FAIL 11 | WARN 1 | SKIP 0 | PASS 10 ]
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Failure ('test-syth-cast.R:93'): Tests prepare_dataset() ────────────────────
  class(prepared_df) (`actual`) not equal to c("data.frame") (`expected`).
  
  `actual`:   "rlang_error" "error" "condition"
  `expected`: "data.frame"                     
  ── Failure ('test-syth-cast.R:98'): Tests prepare_dataset() ────────────────────
  c(ncol(prepared_df), nrow(prepared_df)) (`actual`) not equal to c(31, 525) (`expected`).
  
  `actual` is NULL
  `expected` is a double vector (31, 525)
  ── Failure ('test-syth-cast.R:103'): Tests prepare_dataset() ───────────────────
  as.vector(sapply(prepared_df, class)) (`actual`) not equal to c(...) (`expected`).
  
  `actual` is a list
  `expected` is a character vector ('character', 'integer', 'integer', 'numeric', 'numeric', ...)
  ── Failure ('test-syth-cast.R:122'): Tests compute_synthetic_control() ─────────
  class(synthetic_control) (`actual`) not equal to c("list") (`expected`).
  
  `actual`:   "simpleError" "error" "condition"
  `expected`: "list"                           
  ── Failure ('test-syth-cast.R:131'): Tests compute_synthetic_control() ─────────
  names(synthetic_control) (`actual`) not equal to c("dataprep_out", "synth_out") (`expected`).
  
  `actual`:   "message"      "call"     
  `expected`: "dataprep_out" "synth_out"
  ── Failure ('test-syth-cast.R:141'): Tests compute_result_tables() ─────────────
  class(result_tables) (`actual`) not equal to "list" (`expected`).
  
  `actual`:   "simpleError" "error" "condition"
  `expected`: "list"                           
  ── Failure ('test-syth-cast.R:146'): Tests compute_result_tables() ─────────────
  length(result_tables) (`actual`) not equal to 4 (`expected`).
  
    `actual`: 2
  `expected`: 4
  ── Failure ('test-syth-cast.R:151'): Tests compute_result_tables() ─────────────
  names(result_tables) (`actual`) not equal to c(...) (`expected`).
  
      actual    | expected                                
  [1] "message" - "synthetic_control_composition"      [1]
  [2] "call"    - "variable_importance_and_comparison" [2]
                - "mape_backtest"                      [3]
                - "output_projecao"                    [4]
  ── Failure ('test-syth-cast.R:213'): Tests run_synthetic_forecast() ────────────
  class(synthetic_forecast) (`actual`) not equal to "list" (`expected`).
  
  `actual`:   "simpleError" "error" "condition"
  `expected`: "list"                           
  ── Failure ('test-syth-cast.R:218'): Tests run_synthetic_forecast() ────────────
  length(synthetic_forecast) (`actual`) not equal to 4 (`expected`).
  
    `actual`: 2
  `expected`: 4
  ── Failure ('test-syth-cast.R:223'): Tests run_synthetic_forecast() ────────────
  names(synthetic_forecast) (`actual`) not equal to c(...) (`expected`).
  
      actual    | expected                                
  [1] "message" - "synthetic_control_composition"      [1]
  [2] "call"    - "variable_importance_and_comparison" [2]
                - "mape_backtest"                      [3]
                - "output_projecao"                    [4]
  
  [ FAIL 11 | WARN 1 | SKIP 0 | PASS 10 ]
  Error: Test failures
  Execution halted