(self)
| 185 | @unittest.skipIf(platform.system() == "AIX", "AIX returns PermissionError") |
| 186 | @requires_subprocess() |
| 187 | def test_lockf_share(self): |
| 188 | self.f = open(TESTFN, 'wb+') |
| 189 | cmd = fcntl.LOCK_SH | fcntl.LOCK_NB |
| 190 | fcntl.lockf(self.f, cmd) |
| 191 | mp = multiprocessing.get_context('spawn') |
| 192 | p = mp.Process(target=try_lockf_on_other_process, args=(TESTFN, cmd)) |
| 193 | p.start() |
| 194 | p.join() |
| 195 | fcntl.lockf(self.f, fcntl.LOCK_UN) |
| 196 | self.assertEqual(p.exitcode, 0) |
| 197 | |
| 198 | @cpython_only |
| 199 | def test_flock_overflow(self): |
nothing calls this directly
no test coverage detected