(lock_file: str)
| 182 | |
| 183 | @pytest.mark.asyncio |
| 184 | async def test_close(lock_file: str) -> None: |
| 185 | lock = AsyncReadWriteLock(lock_file, is_singleton=False) |
| 186 | await lock.acquire_write() |
| 187 | assert lock._lock._lock_level == 1 |
| 188 | await lock.close() |
| 189 | assert lock._lock._lock_level == 0 |
| 190 | with pytest.raises(sqlite3.ProgrammingError, match="Cannot operate on a closed database"): |
| 191 | lock._lock._con.execute("SELECT 1;") |
| 192 | |
| 193 | |
| 194 | @pytest.mark.asyncio |
nothing calls this directly
no test coverage detected
searching dependent graphs…