(root: Path)
| 66 | |
| 67 | |
| 68 | def _backends(root: Path) -> Iterator[tuple[str, Callable[[], filelock.BaseFileLock]]]: |
| 69 | # Each entry builds a fresh lock on its own path so no two cases contend. ReadWriteLock is soft-optional, so it is |
| 70 | # measured separately where it applies rather than through this exclusive-lock set. |
| 71 | yield "FileLock", lambda: FileLock(str(root / "file.lock")) |
| 72 | yield "SoftFileLock", lambda: SoftFileLock(str(root / "soft.lock")) |
| 73 | yield "StrictSoftFileLock", lambda: StrictSoftFileLock(str(root / "strict.lock")) |
| 74 | yield "SoftFileLease", lambda: SoftFileLease(str(root / "lease.lock"), lease_duration=30) |
| 75 | |
| 76 | |
| 77 | def _construction(root: Path) -> list[Sample]: |
no test coverage detected