tests/testthat/test_col_types.R

test_that("col_types ODS", {
    x <- read_ods('../testdata/col_types.ods', col_types = NA)
    expect_equal(class(x[,2]), "character")
    x <- read_ods('../testdata/col_types.ods')
    expect_equal(class(x[,2]), "integer")
})

Try the readODS package in your browser

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

readODS documentation built on May 30, 2017, 3:38 a.m.