This package provides a considerable set of test cases which you can easily incorporate in your DBI driver package.

Usage

Install from CRAN via

install.packages("DBItest")

or the development version using

devtools::install_github("r-dbi/DBItest")

In your driver backage, add DBItest to the Suggests:. Then, enable the tests by running

from your package’s directory. This enables testing using testthat (if necessary) and creates, among others, a file test-DBItest.R in the tests/testthat directory. Replace its entire contents by the following:

(This assumes that Kazam() returns an instance of your DBIDriver class. Additional arguments to dbConnect() are specified as named list instead of the NULL argument to make_context().)

The skip argument to test_all() allows specifying skipped tests.

See the package’s documentation and the feature list for a description of the tests.