(self)
| 4480 | |
| 4481 | @unittest.skipIf(fcntl is None, "need fcntl") |
| 4482 | def test_set_inheritable_cloexec(self): |
| 4483 | fd = os.open(__file__, os.O_RDONLY) |
| 4484 | self.addCleanup(os.close, fd) |
| 4485 | self.assertEqual(fcntl.fcntl(fd, fcntl.F_GETFD) & fcntl.FD_CLOEXEC, |
| 4486 | fcntl.FD_CLOEXEC) |
| 4487 | |
| 4488 | os.set_inheritable(fd, True) |
| 4489 | self.assertEqual(fcntl.fcntl(fd, fcntl.F_GETFD) & fcntl.FD_CLOEXEC, |
| 4490 | 0) |
| 4491 | |
| 4492 | @unittest.skipUnless(hasattr(os, 'O_PATH'), "need os.O_PATH") |
| 4493 | def test_get_set_inheritable_o_path(self): |
nothing calls this directly
no test coverage detected