Nothing
context("dtapply")
NMdataConf(reset=TRUE)
test_that("basic - return single value",{
fileRef <- "testReference/dtapply_01.rds"
res <- dtapply(1:3,function(x)paste0("x",x))
expect_equal_to_reference(res,fileRef)
if(FALSE){
ref <- readRDS(fileRef)
ref
res
}
})
test_that("return dt",{
fileRef <- "testReference/dtapply_02.rds"
res <- dtapply(1:3,function(x)list(hey=paste(x)))
expect_equal_to_reference(res,fileRef)
if(FALSE){
ref <- readRDS(fileRef)
ref
res
}
})
test_that("rename columns",{
fileRef <- "testReference/dtapply_03.rds"
res <- dtapply(1:3,function(x)paste0("x",x), value.names="val",element.name="x")
expect_equal_to_reference(res,fileRef)
})
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.