MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_dup

Method test_dup

Lib/test/test_os.py:4808–4814  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

4806 self.assertEqual(os.get_inheritable(wfd), False)
4807
4808 def test_dup(self):
4809 fd1 = os.open(__file__, os.O_RDONLY)
4810 self.addCleanup(os.close, fd1)
4811
4812 fd2 = os.dup(fd1)
4813 self.addCleanup(os.close, fd2)
4814 self.assertEqual(os.get_inheritable(fd2), False)
4815
4816 def test_dup_standard_stream(self):
4817 fd = os.dup(1)

Callers

nothing calls this directly

Calls 5

addCleanupMethod · 0.80
openMethod · 0.45
dupMethod · 0.45
assertEqualMethod · 0.45
get_inheritableMethod · 0.45

Tested by

no test coverage detected