tests/testthat/test_run_all.R

testthat::test_that("Testing run_all",{
  infile <- system.file("extdata", "10^5_reads_test.fq.gz", package = "qckitfastq")
  testfolder <- tempdir()
  
  run_all(infile, testfolder)

  if(.Platform$OS.type != "windows") {
  # test that all expected files are in testfolder
  testthat::expect_equal(length(list.files(testfolder)),17)
  testthat::expect_equal(length(list.files(testfolder,pattern=".csv")),9)
  }
  else {
      testthat::expect_equal(length(list.files(testfolder)),15)
      testthat::expect_equal(length(list.files(testfolder, pattern=".csv")),8)
  }
})

Try the qckitfastq package in your browser

Any scripts or data that you put into this service are public.

qckitfastq documentation built on Nov. 8, 2020, 5:24 p.m.