DBItest v1.4

0

Monthly downloads

0th

Percentile

by Kirill Müller

Testing 'DBI' Back Ends

A helper that tests 'DBI' back ends for conformity to the interface.

Readme

DBItest Travis-CI Build Status AppVeyor Build Status CRAN_Status_Badge

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("rstats-db/DBItest")

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

devtools::use_testthat()
devtools::use_test("DBItest")

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:

DBItest::make_context(Kazam(), NULL)
DBItest::test_all()

(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.

Functions in DBItest

Name Description
DBItest-package DBItest: Testing 'DBI' Back Ends
test_compliance Test full compliance to DBI
DBIspec DBI specification
test_connection Test the "Connection" class
make_context Test contexts
test_transaction Test transaction functions
DBIspec-wip DBI specification (work in progress)
test_getting_started Getting started with testing
test_driver Test the "Driver" class
test_meta Test metadata functions
test_result Test the "Result" class
tweaks Tweaks for DBI tests
test_all Run all tests
make_placeholder_fun Create a function that creates n placeholders
test_sql Test SQL methods
test_stress Stress tests
No Results!

Last month downloads

Details

Date 2016-12-02
License LGPL (>= 2)
LazyData true
Encoding UTF-8
BugReports https://github.com/rstats-db/DBItest/issues
RoxygenNote 5.0.1.9000
VignetteBuilder knitr
Collate 'DBItest.R' 'context.R' 'expectations.R' 'import-dbi.R' 'import-testthat.R' 'run.R' 's4.R' 'spec.R' 'spec-getting-started.R' 'spec-driver-class.R' 'spec-driver-constructor.R' 'spec-driver-data-type.R' 'spec-driver-get-info.R' 'spec-driver.R' 'spec-connection-connect.R' 'spec-connection-data-type.R' 'spec-connection-get-info.R' 'spec-connection.R' 'spec-result-send-query.R' 'spec-result-fetch.R' 'spec-result-get-query.R' 'spec-result-create-table-with-data-type.R' 'spec-result-roundtrip.R' 'spec-result.R' 'spec-sql-quote-string.R' 'spec-sql-quote-identifier.R' 'spec-sql-read-write-table.R' 'spec-sql-read-write-roundtrip.R' 'spec-sql-list-tables.R' 'spec-sql-list-fields.R' 'spec-sql.R' 'spec-meta-is-valid-connection.R' 'spec-meta-is-valid-result.R' 'spec-meta-get-statement.R' 'spec-meta-column-info.R' 'spec-meta-get-row-count.R' 'spec-meta-get-rows-affected.R' 'spec-meta-get-info-result.R' 'spec-meta-bind.R' 'spec-meta-bind-multi-row.R' 'spec-meta-bind-.R' 'spec-meta.R' 'spec-transaction-begin-commit.R' 'spec-transaction-begin-rollback.R' 'spec-transaction-with-transaction.R' 'spec-transaction.R' 'spec-compliance-methods.R' 'spec-compliance-read-only.R' 'spec-compliance.R' 'spec-stress-driver.R' 'spec-stress-connection.R' 'spec-stress.R' 'spec-.R' 'test-all.R' 'test-getting-started.R' 'test-driver.R' 'test-connection.R' 'test-result.R' 'test-sql.R' 'test-meta.R' 'test-transaction.R' 'test-compliance.R' 'test-stress.R' 'tweaks.R' 'utf8.R' 'utils.R'
NeedsCompilation no
Packaged 2016-12-03 07:33:52 UTC; muelleki
Repository CRAN
Date/Publication 2016-12-03 09:38:00

Include our badge in your README

[![Rdoc](http://www.rdocumentation.org/badges/version/DBItest)](http://www.rdocumentation.org/packages/DBItest)