tests/testthat/test-isSqlReservedWord.R

library(testthat)

test_that("isSqlReservedWord works", {
  expect_true(all(isSqlReservedWord(c("TRUE", "CASE", "IF", "#if", "#IF"))))
  expect_false(any(isSqlReservedWord(c("Tbl1", "#tempTable"))))
  expect_warning(isSqlReservedWord("TRUE", warn = T), "reserved")
})

Try the DatabaseConnector package in your browser

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

DatabaseConnector documentation built on May 29, 2024, 6:14 a.m.