mirror of https://github.com/python/cpython
gh-72463: Fix ctypes/test_loading.py so that test_find reports skipped (GH-18312)
This commit is contained in:
parent
a81d9509ee
commit
04d1000071
|
@ -59,11 +59,15 @@ class LoaderTest(unittest.TestCase):
|
|||
self.assertRaises(OSError, cdll.LoadLibrary, self.unknowndll)
|
||||
|
||||
def test_find(self):
|
||||
found = False
|
||||
for name in ("c", "m"):
|
||||
lib = find_library(name)
|
||||
if lib:
|
||||
found = True
|
||||
cdll.LoadLibrary(lib)
|
||||
CDLL(lib)
|
||||
if not found:
|
||||
self.skipTest("Could not find c and m libraries")
|
||||
|
||||
@unittest.skipUnless(os.name == "nt",
|
||||
'test specific to Windows')
|
||||
|
|
Loading…
Reference in New Issue