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
d531b295
Commit
d531b295
authored
Feb 06, 2012
by
Ned Deily
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue #10881: Fix test_site failure with OS X framework builds.
parent
e91e7637
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
10 deletions
+15
-10
Lib/test/test_site.py
Lib/test/test_site.py
+13
-10
Misc/NEWS
Misc/NEWS
+2
-0
No files found.
Lib/test/test_site.py
View file @
d531b295
...
@@ -223,7 +223,19 @@ class HelperFunctionsTests(unittest.TestCase):
...
@@ -223,7 +223,19 @@ class HelperFunctionsTests(unittest.TestCase):
self
.
assertEqual
(
len
(
dirs
),
1
)
self
.
assertEqual
(
len
(
dirs
),
1
)
wanted
=
os
.
path
.
join
(
'xoxo'
,
'Lib'
,
'site-packages'
)
wanted
=
os
.
path
.
join
(
'xoxo'
,
'Lib'
,
'site-packages'
)
self
.
assertEqual
(
dirs
[
0
],
wanted
)
self
.
assertEqual
(
dirs
[
0
],
wanted
)
elif
(
sys
.
platform
==
"darwin"
and
sysconfig
.
get_config_var
(
"PYTHONFRAMEWORK"
)):
# OS X framework builds
site
.
PREFIXES
=
[
'Python.framework'
]
dirs
=
site
.
getsitepackages
()
self
.
assertEqual
(
len
(
dirs
),
3
)
wanted
=
os
.
path
.
join
(
'/Library'
,
sysconfig
.
get_config_var
(
"PYTHONFRAMEWORK"
),
sys
.
version
[:
3
],
'site-packages'
)
self
.
assertEqual
(
dirs
[
2
],
wanted
)
elif
os
.
sep
==
'/'
:
elif
os
.
sep
==
'/'
:
# OS X non-framwework builds, Linux, FreeBSD, etc
self
.
assertEqual
(
len
(
dirs
),
2
)
self
.
assertEqual
(
len
(
dirs
),
2
)
wanted
=
os
.
path
.
join
(
'xoxo'
,
'lib'
,
'python'
+
sys
.
version
[:
3
],
wanted
=
os
.
path
.
join
(
'xoxo'
,
'lib'
,
'python'
+
sys
.
version
[:
3
],
'site-packages'
)
'site-packages'
)
...
@@ -231,21 +243,12 @@ class HelperFunctionsTests(unittest.TestCase):
...
@@ -231,21 +243,12 @@ class HelperFunctionsTests(unittest.TestCase):
wanted
=
os
.
path
.
join
(
'xoxo'
,
'lib'
,
'site-python'
)
wanted
=
os
.
path
.
join
(
'xoxo'
,
'lib'
,
'site-python'
)
self
.
assertEqual
(
dirs
[
1
],
wanted
)
self
.
assertEqual
(
dirs
[
1
],
wanted
)
else
:
else
:
# other platforms
self
.
assertEqual
(
len
(
dirs
),
2
)
self
.
assertEqual
(
len
(
dirs
),
2
)
self
.
assertEqual
(
dirs
[
0
],
'xoxo'
)
self
.
assertEqual
(
dirs
[
0
],
'xoxo'
)
wanted
=
os
.
path
.
join
(
'xoxo'
,
'lib'
,
'site-packages'
)
wanted
=
os
.
path
.
join
(
'xoxo'
,
'lib'
,
'site-packages'
)
self
.
assertEqual
(
dirs
[
1
],
wanted
)
self
.
assertEqual
(
dirs
[
1
],
wanted
)
# let's try the specific Apple location
if
(
sys
.
platform
==
"darwin"
and
sysconfig
.
get_config_var
(
"PYTHONFRAMEWORK"
)):
site
.
PREFIXES
=
[
'Python.framework'
]
dirs
=
site
.
getsitepackages
()
self
.
assertEqual
(
len
(
dirs
),
3
)
wanted
=
os
.
path
.
join
(
'/Library'
,
'Python'
,
sys
.
version
[:
3
],
'site-packages'
)
self
.
assertEqual
(
dirs
[
2
],
wanted
)
class
PthFile
(
object
):
class
PthFile
(
object
):
"""Helper class for handling testing of .pth files"""
"""Helper class for handling testing of .pth files"""
...
...
Misc/NEWS
View file @
d531b295
...
@@ -113,6 +113,8 @@ Core and Builtins
...
@@ -113,6 +113,8 @@ Core and Builtins
Library
Library
-------
-------
- Issue #10881: Fix test_site failure with OS X framework builds.
- Issue #964437 Make IDLE help window non-modal.
- Issue #964437 Make IDLE help window non-modal.
Patch by Guilherme Polo and Roger Serwy.
Patch by Guilherme Polo and Roger Serwy.
...
...
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