Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DBI specification in prose #88

Closed
8 tasks done
krlmlr opened this issue Jul 31, 2016 · 0 comments
Closed
8 tasks done

DBI specification in prose #88

krlmlr opened this issue Jul 31, 2016 · 0 comments
Assignees

Comments

@krlmlr
Copy link
Member

krlmlr commented Jul 31, 2016

Currently at ?DBIspec

  • Convert to Markdown
  • Getting started
  • Driver
  • Connection
  • Result
  • SQL
  • Meta
  • Compliance

Rearrange specifications as necessary.

@krlmlr krlmlr added the ready label Jul 31, 2016
@krlmlr krlmlr self-assigned this Jul 31, 2016
@krlmlr krlmlr added in progress and removed ready labels Jul 31, 2016
krlmlr pushed a commit that referenced this issue Aug 1, 2016
- Document and enhance test for `dbDataType("DBIDriver", "ANY")` (#88).
krlmlr pushed a commit that referenced this issue Aug 3, 2016
- Document and enhance test for `dbDataType("DBIDriver", "ANY")` (#88).
krlmlr added a commit that referenced this issue Sep 17, 2016
krlmlr added a commit that referenced this issue Sep 17, 2016
krlmlr added a commit that referenced this issue Oct 1, 2016
krlmlr added a commit that referenced this issue Oct 1, 2016
- Use markdown in documentation.
krlmlr added a commit that referenced this issue Oct 1, 2016
- Description of parametrized queries and statements (#88).
krlmlr added a commit that referenced this issue Oct 1, 2016
- Description of parametrized queries and statements (#88).
- Use markdown in documentation.
- Refactor tests for `dbBind()`, test is run by `BindTester` class, and behavior is specified by members and by instances of the new `BindTesterExtra` class.
krlmlr added a commit that referenced this issue Oct 3, 2016
krlmlr added a commit that referenced this issue Oct 3, 2016
- Align description of binding with code.
krlmlr added a commit that referenced this issue Dec 4, 2016
- Use markdown in documentation.
- Description of parametrized queries and statements (#88).
- New hidden `DBIspec-wip` page for work-in-progress documentation.
- Get rid of "Format" and "Usage" sections, and aliases, in the specs.

- Not testing for presence of `max.connections` element in `dbGetInfo(Driver)` (r-dbi/DBI#56).
- Test multi-row binding for queries and statements (#96).
- New `ellipsis` check that verifies that all implemented DBI methods contain `...` in their formals. This excludes `show()` and all methods defined in this or other packages.
- Refactored `bind_` tests to use the new `parameter_pattern` tweak (#95).
- Rough draft of transaction tests (#36).
- New `fetch_zero_rows` test, split from `fetch_premature_close`.
- The "compliance" test tests that the backend package exports exactly one subclass of each DBI virtual class.
- Document and enhance test for `dbDataType("DBIDriver", "ANY")` (#88).
- Minor corrections for "bind" tests.

- Isolate stress tests from main test suite (#92).
- Refactor test specification in smaller modules, isolated from actual test execution (#81). This breaks the documentation of the tests, which will be substituted by a DBI specification in prose.
- Align description of binding with code.
- Refactor tests for `dbBind()`, test is run by `BindTester` class, and behavior is specified by members and by instances of the new `BindTesterExtra` class.
- The `skip` argument to the `test_()` functions is again evaluated with `perl = TRUE` to support negative lookaheads (#33).
- Use `dbSendStatement()` and `dbExecute()` where appropriate.
- Avoid empty subsections in Rd documentation to satisfy `R CMD check` (#81).
krlmlr added a commit that referenced this issue Jan 1, 2017
krlmlr added a commit that referenced this issue Jan 31, 2017
…. Fixes #66. Fixes #79.

- `DBItest_tweaks` class gains a `$` method, accessing an undefined tweak now raises an error.
- The arguments of the `tweaks()` function now have default values that further describe their intended usage.
- New `with_closed_connection()`, `with_invalid_connection()`, `with_result()` and `with_remove_test_table()` helpers, and `expect_visible()`, `expect_inbisible_true()`, and `expect_equal_df()` expectations for more concise tests.
- Added prose specifications, and enhanced/modified/renamed tests for `dbConnect()`, `dbDisconnect()`, `dbDataType()`, `dbSendQuery()`, `dbFetch()`, `dbClearResult()`, `dbGetQuery()`, `dbSendStatement()`, `dbExecute()`, `dbQuoteIdentifier()`, `dbQuoteString()`, `dbReadTable()`, `dbWriteTable()`, `dbRemoveTable()`, `dbExistsTable()`, and `dbListTables()` (#88).
- Testing that a warning is given if the user forgets to call `dbDisconnect()` or `dbClearResult()` (#103).
- Added roundtrip test for time values (#14).
- Added tweaks for handling date, time, timestamp, ... (#53, #76).
- Test that `dbFetch()` on update-only query returns warning (#66).
- Numeric roundtrip accepts conversion of `NaN` to `NA` (#79).
krlmlr added a commit that referenced this issue Jan 31, 2017
- `DBItest_tweaks` class gains a `$` method, accessing an undefined tweak now raises an error.
- The arguments of the `tweaks()` function now have default values that further describe their intended usage.
- New `with_closed_connection()`, `with_invalid_connection()`, `with_result()` and `with_remove_test_table()` helpers, and `expect_visible()`, `expect_inbisible_true()`, and `expect_equal_df()` expectations for more concise tests.
- Added prose specifications, and enhanced/modified/renamed tests for `dbConnect()`, `dbDisconnect()`, `dbDataType()`, `dbSendQuery()`, `dbFetch()`, `dbClearResult()`, `dbGetQuery()`, `dbSendStatement()`, `dbExecute()`, `dbQuoteIdentifier()`, `dbQuoteString()`, `dbReadTable()`, `dbWriteTable()`, `dbRemoveTable()`, `dbExistsTable()`, and `dbListTables()` (#88).
- Testing that a warning is given if the user forgets to call `dbDisconnect()` or `dbClearResult()` (#103).
- Added roundtrip test for time values (#14).
- Added tweaks for handling date, time, timestamp, ... (#53, #76).
- Test that `dbFetch()` on update-only query returns warning (#66).
- Numeric roundtrip accepts conversion of `NaN` to `NA` (#79).
krlmlr added a commit that referenced this issue Feb 25, 2017
krlmlr added a commit that referenced this issue Feb 25, 2017
- Added prose specifications, and enhanced/modified/renamed tests for `dbIsValid()`, `dbHasCompleted()`, `dbGetStatement()`, `dbGetRowCount()`, `dbGetRowsAffected()`, and `dbBind()` (#88).
krlmlr added a commit that referenced this issue Feb 25, 2017
- Added prose specifications, and enhanced/modified/renamed tests for `dbIsValid()`, `dbHasCompleted()`, `dbGetStatement()`, `dbGetRowCount()`, `dbGetRowsAffected()`, and `dbBind()` (#88).
krlmlr added a commit that referenced this issue Feb 26, 2017
@krlmlr krlmlr closed this as completed in de64f7d Feb 26, 2017
@ghost ghost removed the in progress label Feb 26, 2017
krlmlr added a commit that referenced this issue Feb 26, 2017
- Added prose specifications, and enhanced/modified/renamed tests for `dbBegin()`, `dbCommit()`, `dbRollback()`, and `dbWithTransaction()`. Most tests now come with a corresponding prose, only those where the behavior is not finally decided don't have a prose version yet (#88).
krlmlr added a commit that referenced this issue Jun 19, 2017
Finalize specification. Most tests now come with a corresponding prose,
only those where the behavior is not finally decided don't have a prose
version yet (#88).

New tests
---------

- Test behavior of methods in presence of placeholders (#120).
- Test column name mismatch behavior for appending tables (#93).
- Test that `dbBind()` against factor works but raises a warning (#91).
- Test roundtrip of alternating empty and non-empty strings (#42).
- Test multiple columns of different types in one statement or table
(#35).
- Test `field.types` argument to `dbWriteTable()` (#12).
- Added tests for invalid or closed connection argument to all methods
that expect a connection as first argument (#117).
- Enabled test that tests a missing `dbDisconnect()`.
- Add test for unambiguous escaping of identifiers
(r-dbi/RSQLite#123).
- Reenable tests for visibility (#89).
- Fix and specify 64-bit roundtrip test.
- 64-bit integers only need to be coercible to `numeric` and `character`
(#74).
- Added roundtrip test for time values (#14).
- Added tweaks for handling date, time, timestamp, ... (#53, #76).
- Test that `dbFetch()` on update-only query returns warning (#66).

Adapted tests
-------------

- `NULL` is a valid value for the `row.names` argument, same as `FALSE`.
- A column named `row_names` receives no special handling (#54).
- A warning (not an error anymore) is expected when calling
`dbDisconnect()` on a closed or invalid connection.
- `row.names = FALSE` is now the default for methods that read or write
tables.
- Add `NA` to beginning and end of columns in table roundtrip tests
(#24).
- Stricter tests for confusion of named and unnamed SQL parameters and
placeholders (#107).
- Also check names of all returned data frames.
- The return value for all calls to `dbGetQuery()`, `dbFetch()`, and
`dbReadTable()` is now checked for consistency (all columns have the
same length, length matches number of rows) (#126).
- Removed stress tests that start a new session.
- Allow `hms` (or other subclasses of `difftime`) to be returned as time
class (#135, @jimhester).
- Test that dates are of type `numeric` (#99, @jimhester).
- Replace `POSIXlt` by `POSIXct` (#100, @jimhester).
- Use `"PST8PDT"` instead of `"PST"` as time zone (#110, @thrasibule).
- Added tests for support of `blob` objects (input and output), but
backends are not required to return `blob` objects (#98).
- The `logical_return`, `date_typed` and `timestamp_typed` tweaks are
respected by the bind tests.
- Fixed tests involving time comparison; now uses UTC timezone and
compares against a `difftime`.
- Tests for roundtrip of character values now includes tabs, in addition
to many other special characters (#85).
- Make sure at least one table exists in the `dbListTables()` test.
- Fix roundtrip tests for raw columns: now expecting `NULL` and not `NA`
entries for SQL NULL values.
- Fix `expect_equal_df()` for list columns.
- Testing that a warning is given if the user forgets to call
`dbDisconnect()` or `dbClearResult()` (#103).
- Numeric roundtrip accepts conversion of `NaN` to `NA` (#79).

Internal
--------

- Fix R CMD check errors.
- Internal consistency checks (#114).
- Skip patterns that don't match any of the tests now raise a warning
(#84).
- New `test_some()` to test individual tests (#136).
- Use desc instead of devtools (#40).
- All unexpected warnings are now reported as test failures (#113).
- `DBItest_tweaks` class gains a `$` method, accessing an undefined
tweak now raises an error.
- The arguments of the `tweaks()` function now have default values that
further describe their intended usage.
- New `with_closed_connection()`, `with_invalid_connection()`,
`with_result()` and `with_remove_test_table()` helpers, and
`expect_visible()`, `expect_inbisible_true()`, and `expect_equal_df()`
expectations for more concise tests.
@github-actions github-actions bot locked and limited conversation to collaborators Dec 6, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant