tests/testthat/test_format_feather.R

context("feather imports/exports")
skip_if_not_installed("arrow")
require("datasets")

test_that("Export to feather", {
    skip_if_not_installed("arrow")
    expect_true(export(iris, "iris.feather") %in% dir())
})

test_that("Import from feather", {
    skip_if_not_installed("arrow")
    expect_true(is.data.frame(import("iris.feather")))
})

unlink("iris.feather")

Try the rio package in your browser

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

rio documentation built on Sept. 19, 2023, 5:06 p.m.