r10511: add tests for db-reader and db-writer