| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
This PR either uses the memory_database() resource management helper from Lib/test/test_sqlite3/test_dbapi.py, or introduces explicit resource management via setUp()/tearDown() test case methods. |
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM.
I would suggest moving memory_database() to a new utils.py file. For me, it's surprising that tests import other tests. See for example Lib/test/test_asyncio/utils.py.
Sorry, something went wrong.
|
I don't know the DB API, but I'm surprised that with connect() as db: ... doesn't close the database :-( |
Sorry, something went wrong.
- Move test utility functions to util.py - Use memory database mixin - Add check() helper for closed connection tests - Address other remarks by Nikita
|
I think all your remarks are addressed now; PTAL :) |
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM.
If you want, you can replace from test.test_sqlite3.util import with from .util import.
Sorry, something went wrong.
|
Thanks for the review, Victor and Nikita! |
Sorry, something went wrong.
There was a problem hiding this comment.
My first sqlite3 PR review ✅
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Uh oh!
There was an error while loading. Please reload this page.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.