tests/testthat/test-sql-build.R

test_that("rendering table wraps in SELECT *", {
  out <- copy_to_test("sqlite", tibble(x = 1), name = "test-sql-build")
  expect_snapshot(out %>% sql_render())
  expect_equal(out %>% collect(), tibble(x = 1))
})

Try the dbplyr package in your browser

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

dbplyr documentation built on Oct. 26, 2023, 9:06 a.m.