Commit 20d352c
fix: close leaked InMemoryCatalog in test_inspect.py catalog fixture
Fixes ResourceWarning unclosed database connections in test_inspect.py tests.
The local catalog fixture (lines 38-42) returned the InMemoryCatalog without
yielding or calling close(), leaving SQLite connections uncovered.
Changed the fixture to a generator that yields and closes the catalog on
teardown, matching the pattern established in conftest.py and elsewhere on
this branch for issue #2530.
All 4 tests in test_inspect.py now pass without ResourceWarnings.
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>1 parent f555e51 commit 20d352c
1 file changed
Lines changed: 4 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
18 | 19 | | |
19 | 20 | | |
20 | 21 | | |
| |||
36 | 37 | | |
37 | 38 | | |
38 | 39 | | |
39 | | - | |
| 40 | + | |
40 | 41 | | |
41 | 42 | | |
42 | | - | |
| 43 | + | |
| 44 | + | |
43 | 45 | | |
44 | 46 | | |
45 | 47 | | |
| |||
0 commit comments