Running examples in 'compstatr-Ex.R' failed
The error most likely occurred in:

> ### Name: cs_load_year
> ### Title: Create Year List Object
> ### Aliases: cs_load_year
> 
> ### ** Examples
> 
> # create temporary directory
> tmpdir <- tempdir()
> fs::dir_create(paste0(tmpdir,"/data/"))
> 
> # load sample files into temporary directory
> cs_example(path = paste0(tmpdir,"/data/"))
> 
> # prep sample files
> cs_prep_year(path = paste0(tmpdir,"/data/"))
> 
> # load sample files
> yearList17 <- cs_load_year(path = paste0(tmpdir,"/data/"))
> 
> # delete data
> fs::dir_delete(paste0(tmpdir,"/data/"))
Error: [EBUSY] Failed to remove 'D:/temp/RtmpsbRgO0/data/april2017.csv': resource busy or locked
Execution halted
Running examples in 'compstatr-Ex.R' failed
The error most likely occurred in:

> ### Name: cs_load_year
> ### Title: Create Year List Object
> ### Aliases: cs_load_year
> 
> ### ** Examples
> 
> # create temporary directory
> tmpdir <- tempdir()
> fs::dir_create(paste0(tmpdir,"/data/"))
> 
> # load sample files into temporary directory
> cs_example(path = paste0(tmpdir,"/data/"))
> 
> # prep sample files
> cs_prep_year(path = paste0(tmpdir,"/data/"))
> 
> # load sample files
> yearList17 <- cs_load_year(path = paste0(tmpdir,"/data/"))
> 
> # delete data
> fs::dir_delete(paste0(tmpdir,"/data/"))
Error: [EBUSY] Failed to remove 'C:/r_packages/pkgcheck/CRAN/compstatr/tmp/RtmpoxsKfR/data/april2017.csv': resource busy or locked
Execution halted
Running 'testthat.R'
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > library(testthat)
  > library(compstatr)
  > 
  > test_check("compstatr")
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • On CRAN (3)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test_load_year.R:55:1): (code run outside of `test_that()`) ──────────
  <EBUSY/fs_error/error/condition>
  Error: [EBUSY] Failed to remove 'C:/r_packages/pkgcheck/CRAN/compstatr/tmp/RtmpATj8TK/data/december2017.csv': resource busy or locked
  Backtrace:
      █
   1. └─fs::file_delete(paste0(tmpdir, "/data/december2017.csv")) test_load_year.R:55:0
  
  [ FAIL 1 | WARN 1 | SKIP 3 | PASS 225 ]
  Error: Test failures
  Execution halted
Running examples in 'compstatr-Ex.R' failed
The error most likely occurred in:

> ### Name: cs_load_year
> ### Title: Create Year List Object
> ### Aliases: cs_load_year
> 
> ### ** Examples
> 
> # create temporary directory
> tmpdir <- tempdir()
> fs::dir_create(paste0(tmpdir,"/data/"))
> 
> # load sample files into temporary directory
> cs_example(path = paste0(tmpdir,"/data/"))
> 
> # prep sample files
> cs_prep_year(path = paste0(tmpdir,"/data/"))
> 
> # load sample files
> yearList17 <- cs_load_year(path = paste0(tmpdir,"/data/"))
> 
> # delete data
> fs::dir_delete(paste0(tmpdir,"/data/"))
Error: [EBUSY] Failed to remove 'D:/temp/RtmpaWOPzf/data/april2017.csv': resource busy or locked
Execution halted
Running examples in 'compstatr-Ex.R' failed
The error most likely occurred in:

> ### Name: cs_load_year
> ### Title: Create Year List Object
> ### Aliases: cs_load_year
> 
> ### ** Examples
> 
> # create temporary directory
> tmpdir <- tempdir()
> fs::dir_create(paste0(tmpdir,"/data/"))
> 
> # load sample files into temporary directory
> cs_example(path = paste0(tmpdir,"/data/"))
> 
> # prep sample files
> cs_prep_year(path = paste0(tmpdir,"/data/"))
> 
> # load sample files
> yearList17 <- cs_load_year(path = paste0(tmpdir,"/data/"))
> 
> # delete data
> fs::dir_delete(paste0(tmpdir,"/data/"))
Error: [EBUSY] Failed to remove 'D:/temp/RtmpsVq0sK/data/april2017.csv': resource busy or locked
Execution halted