Running ‘testthat.R’
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(prettifyAddins)
  > 
  > test_check("prettifyAddins")
  ── Skip (test-CLANG.R:2:3): CLANG prettify C++ with default `tabSize` ──────────
  Reason: Sys.which("clang-format") == ""  is TRUE
  
  ── Skip (test-CLANG.R:17:3): CLANG prettify C++ with given `tabSize` ───────────
  Reason: Sys.which("clang-format") == ""  is TRUE
  
  ── Skip (test-PhantomJS.R:2:3): PhantomJS reindent C++ with default `tabSize` ──
  Reason: 'phantomjs' not found
  
  ── Skip (test-PhantomJS.R:17:3): PhantomJS reindent C++ with given `tabSize` ───
  Reason: 'phantomjs' not found
  
  ── Skip (test-PhantomJS.R:32:3): PhantomJS reindent C++ from a file ────────────
  Reason: 'phantomjs' not found
  
  ── Skip (test-PhantomJS.R:49:3): PhantomJS reindent Julia with default `tabSize`
  Reason: 'phantomjs' not found
  
  ── ERROR (test-V8.R:9:3): V8 prettify JavaScript with default `tabSize` ────────
  Error: 'V8' has failed to source some files. Probably your version of the 'V8' engine is not recent enough.
  Backtrace:
      █
   1. └─prettifyAddins::prettify_V8(code, "javascript") test-V8.R:9:2
   2.   └─base::tryCatch(...)
   3.     └─base:::tryCatchList(expr, classes, parentenv, handlers)
   4.       └─base:::tryCatchOne(expr, names, parentenv, handlers[[1L]])
   5.         └─value[[3L]](cond)
  
  ── ERROR (test-V8.R:24:3): V8 prettify JavaScript with given `tabSize` ─────────
  Error: 'V8' has failed to source some files. Probably your version of the 'V8' engine is not recent enough.
  Backtrace:
      █
   1. └─prettifyAddins::prettify_V8(code, "javascript", tabSize = 4) test-V8.R:24:2
   2.   └─base::tryCatch(...)
   3.     └─base:::tryCatchList(expr, classes, parentenv, handlers)
   4.       └─base:::tryCatchOne(expr, names, parentenv, handlers[[1L]])
   5.         └─value[[3L]](cond)
  
  ── ERROR (test-V8.R:39:3): V8 reindent JavaScript with default `tabSize` ───────
  Error: TypeError: Object   has no method 'repeat'
  Backtrace:
      █
   1. └─prettifyAddins::reindent_V8(code, "javascript") test-V8.R:39:2
   2.   └─ctx$eval(indentify)
   3.     └─V8:::evaluate_js(src, serialize = serialize)
   4.       ├─V8:::get_str_output(...)
   5.       └─V8:::context_eval(join(src), private$context, serialize)
  
  ── Skip (test-V8.R:48:3): V8 reindent JavaScript with given `tabSize` ──────────
  Reason: V8 engine too old.
  
  ── Skipped tests  ──────────────────────────────────────────────────────────────
  ● 'phantomjs' not found (4)
  ● Sys.which("clang-format") == ""  is TRUE (2)
  ● V8 engine too old. (1)
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  ERROR (test-V8.R:9:3): V8 prettify JavaScript with default `tabSize`
  ERROR (test-V8.R:24:3): V8 prettify JavaScript with given `tabSize`
  ERROR (test-V8.R:39:3): V8 reindent JavaScript with default `tabSize`
  
  [ FAIL 3 | WARN 0 | SKIP 7 | PASS 3 ]
  Error: Test failures
  Execution halted