Call db_flush in test.  Fix documentation / implementation mismatch.