mirror of
https://github.com/python/cpython.git
synced 2025-12-04 08:34:25 +00:00
Change a test assertion to a conditional so the test will pass on
Windows.
This commit is contained in:
parent
13853a67cf
commit
8772b18bc4
1 changed files with 3 additions and 2 deletions
|
|
@ -265,10 +265,11 @@ class ImportTests(unittest.TestCase):
|
||||||
# When loading an extension module and the file is None, open one
|
# When loading an extension module and the file is None, open one
|
||||||
# on the behalf of imp.load_dynamic().
|
# on the behalf of imp.load_dynamic().
|
||||||
# Issue #15902
|
# Issue #15902
|
||||||
name = '_heapq'
|
name = '_testimportmultiple'
|
||||||
found = imp.find_module(name)
|
found = imp.find_module(name)
|
||||||
assert found[2][2] == imp.C_EXTENSION
|
|
||||||
found[0].close()
|
found[0].close()
|
||||||
|
if found[2][2] != imp.C_EXTENSION:
|
||||||
|
return
|
||||||
imp.load_module(name, None, *found[1:])
|
imp.load_module(name, None, *found[1:])
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue