MCPcopy Create free account
hub / github.com/tox-dev/filelock / test_wrong_platform

Function test_wrong_platform

tests/test_filelock.py:647–658  ·  view source on GitHub ↗
(tmp_path: Path)

Source from the content-addressed store, hash-verified

645
646
647def test_wrong_platform(tmp_path: Path) -> None:
648 assert not inspect.isabstract(UnixFileLock)
649 assert not inspect.isabstract(WindowsFileLock)
650 assert inspect.isabstract(BaseFileLock)
651
652 lock_type = UnixFileLock if sys.platform == "win32" else WindowsFileLock
653 lock = lock_type(tmp_path / "lockfile")
654
655 with pytest.raises(NotImplementedError):
656 lock.acquire()
657 with pytest.raises(NotImplementedError):
658 lock._release()
659
660
661@pytest.mark.skipif(sys.platform == "win32", reason="flock not run on windows")

Callers

nothing calls this directly

Calls 2

acquireMethod · 0.45
_releaseMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…