Running ‘test-all.R’ [37s/57s]
Running the tests in ‘tests/test-all.R’ failed.
Complete output:
  > library(testthat)
  > library(nat)
  Loading required package: rgl
  Registered S3 method overwritten by 'nat':
    method             from
    as.mesh3d.ashape3d rgl 
  Some nat functions depend on a CMTK installation. See ?cmtk and README.md for details.
  
  Attaching package: 'nat'
  
  The following objects are masked from 'package:base':
  
      intersect, setdiff, union
  
  > library(httr)
  > 
  > # suppress RGL in headless environments (some CRAN build machines fail otherwise)
  > if(!interactive())
  +   Sys.setenv(RGL_USE_NULL=TRUE)
  > 
  > # Is internet accessible?
  > internet.ok = identical(
  +   try(
  +     status_code(
  +       HEAD("http://flybrain.mrc-lmb.cam.ac.uk/", timeout(2))
  +     ),
  +     silent = TRUE
  +   ),
  +   200L
  + )
  > 
  > if(Sys.getenv('NOT_CRAN') == "true" && internet.ok) {
  +   # note that we want to run all tests requiring internet access
  +   Sys.setenv(NAT_INTERNET_TESTS="TRUE")
  +   # Run all test files
  +   test_check("nat")
  + } else {
  +   # We're on CRAN or flybrain is inacessible, so don't run anything involving 
  +   # remote files
  +   Sys.setenv(NAT_INTERNET_TESTS="")
  +   test_check("nat", filter="^[^.]+")
  + }
    adding: testdata/neuron/testneuron_am3d.am (deflated 45%)
    adding: testdata/neuron/testneuron_lineset.am (deflated 69%)
    adding: DA1/EBH11R.swc (deflated 53%)
    adding: DA1/EBH20R.swc (deflated 54%)
    adding: DA1/EBI12L.swc (deflated 54%)
    adding: DL3/EBH20L.swc (deflated 54%)
    adding: DL3/EBI22R.swc (deflated 53%)
  [ FAIL 1 | WARN 20 | SKIP 5 | PASS 787 ]
  
  ══ Skipped tests (5) ═══════════════════════════════════════════════════════════
  • On CRAN (2): 'test-cmtkreg.R:58:3', 'test-ndigest.R:9:3'
  • empty test (3): 'test-neuron-io.R:992:1', 'test-neuronlist.R:90:1',
    'test-potential_synapses.R:3:1'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-neuron.R:239:3'): we can subset a neuron with a vertex sequence ──
  Error in `delete_vertices(graph = graph, v = v)`: At vendor/cigraph/src/graph/iterators.c:828 : Cannot create iterator, invalid vertex ID. Invalid vertex ID
  Backtrace:
      ▆
   1. ├─testthat::expect_is(...) at test-neuron.R:239:3
   2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
   3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
   4. ├─base::subset(n, n_graph_dfs$order, invert = T)
   5. └─nat:::subset.neuron(n, n_graph_dfs$order, invert = T)
   6.   └─nat::prune_vertices(x, r, invert = !invert, ...)
   7.     └─igraph::delete.vertices(g, verticestoprune)
   8.       └─igraph::delete_vertices(graph = graph, v = v)
  
  [ FAIL 1 | WARN 20 | SKIP 5 | PASS 787 ]
  Error: Test failures
  Execution halted