(
lock_file: str,
first: Literal["read", "write"],
second: Literal["read", "write"],
)
| 358 | ) |
| 359 | @pytest.mark.timeout(15) |
| 360 | def test_sequential_lock_modes( |
| 361 | lock_file: str, |
| 362 | first: Literal["read", "write"], |
| 363 | second: Literal["read", "write"], |
| 364 | ) -> None: |
| 365 | lock = ReadWriteLock(lock_file) |
| 366 | for mode in (first, second): |
| 367 | acquire = lock.read_lock if mode == "read" else lock.write_lock |
| 368 | with acquire(): |
| 369 | pass |
| 370 | |
| 371 | |
| 372 | @pytest.mark.parametrize( |
nothing calls this directly
no test coverage detected