tests/testthat/test-utils.R

test_that("arrow-to-bin roundtrip", {
  expected_table <- arrow::Table$create(mtcars)
  bytes <- arrow_to_bin(expected_table)
  actual_table <- bin_to_arrow(bytes)

  expect_equal(actual_table, expected_table)
})

Try the foundry package in your browser

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

foundry documentation built on May 31, 2023, 6:05 p.m.