Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
a2898c1d
Commit
a2898c1d
authored
Apr 20, 2012
by
Brett Cannon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Try to debug a Windows failure on the buildbots.
parent
c33f3f23
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
Lib/test/test_import.py
Lib/test/test_import.py
+4
-1
No files found.
Lib/test/test_import.py
View file @
a2898c1d
...
...
@@ -337,7 +337,7 @@ class ImportTests(unittest.TestCase):
del
sys
.
path
[
0
]
remove_files
(
TESTFN
)
@
unittest
.
skipUnless
(
sys
.
platform
==
"win32"
,
"Windows
specific"
)
@
unittest
.
skipUnless
(
sys
.
platform
==
"win32"
,
"Windows
-
specific"
)
def
test_extension_import_fail
(
self
):
# Issue 1559549 added `name` and `path` attributes to ImportError
# in order to provide better detail. Issue 10854 implemented those
...
...
@@ -352,6 +352,9 @@ class ImportTests(unittest.TestCase):
import
extension
self
.
assertEqual
(
err
.
exception
.
name
,
pkg_name
)
# The path we get back has the dot-slash, e.g., ".\\extension.pyd"
self
.
assertIsNotNone
(
err
.
exception
.
path
,
'unexpected None for ImportError.path: '
'{!r}'
.
format
(
err
.
exception
))
self
.
assertEqual
(
os
.
path
.
relpath
(
err
.
exception
.
path
),
pkg_file
)
finally
:
unlink
(
pkg_file
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment