gh-136156: Skip test_tempfile.test_link_tmpfile() on Android (#136430)

Adds a test skip on platforms where hard links are not available (which includes Android).
This commit is contained in:
Victor Stinner 2025-07-10 00:17:21 +02:00 committed by GitHub
parent 92f392ad9e
commit 92b33c9590
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1594,6 +1594,7 @@ if tempfile.NamedTemporaryFile is not tempfile.TemporaryFile:
mock_close.assert_called()
self.assertEqual(os.listdir(dir), [])
@os_helper.skip_unless_hardlink
@unittest.skipUnless(tempfile._O_TMPFILE_WORKS, 'need os.O_TMPFILE')
@unittest.skipUnless(os.path.exists('/proc/self/fd'),
'need /proc/self/fd')