tests/testthat/test_func.R

library(testthat)
library(rtravis)

context('test')

testthat::test_that('a test',{

  path <- tempfile(pattern = 'myfile',fileext = '.txt')
  
  cat('this is a test',file = path,sep='\n')
  
  expect_equal(readLines(path),'this is a test')
  
})
yonicd/rtravis documentation built on May 5, 2019, 12:31 p.m.