Author: Ronny Pfannschmidt <ronny.pfannschm...@gmx.de>
Branch: stdlib-unification
Changeset: r54344:39affc663dc5
Date: 2012-04-13 22:02 +0200
http://bitbucket.org/pypy/pypy/changeset/39affc663dc5/

Log:    fix tests for initial sys.path

diff --git a/pypy/module/sys/test/test_initialpath.py 
b/pypy/module/sys/test/test_initialpath.py
--- a/pypy/module/sys/test/test_initialpath.py
+++ b/pypy/module/sys/test/test_initialpath.py
@@ -3,12 +3,10 @@
 from pypy.module.sys.version import PYPY_VERSION, CPYTHON_VERSION
 
 def build_hierarchy(prefix):
-    dirname = '%d.%d' % (CPYTHON_VERSION[0],
-                         CPYTHON_VERSION[1])
+    dirname = '%d.%d' % CPYTHON_VERSION[:2]
     a = prefix.join('lib_pypy').ensure(dir=1)
-    b = prefix.join('lib-python', 'modified-%s' % dirname).ensure(dir=1)
-    c = prefix.join('lib-python', dirname).ensure(dir=1)
-    return a, b, c
+    b = prefix.join('lib-python', dirname).ensure(dir=1)
+    return a, b
 
 
 def test_stdlib_in_prefix(tmpdir):
@@ -18,10 +16,7 @@
     assert path[:len(dirs)] == map(str, dirs)
 
 def test_include_libtk(tmpdir):
-    lib_pypy, lib_python_modified, lib_python = build_hierarchy(tmpdir)
-    lib_tk_modified = lib_python_modified.join('lib-tk')
+    lib_pypy, lib_python = build_hierarchy(tmpdir)
     lib_tk = lib_python.join('lib-tk')
     path = getinitialpath(None, str(tmpdir))
-    i = path.index(str(lib_tk_modified))
-    j = path.index(str(lib_tk))
-    assert i < j
+    assert lib_tk in path
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to