Author: Armin Rigo <[email protected]>
Branch:
Changeset: r47129:e556f833d5d4
Date: 2011-09-07 12:58 +0200
http://bitbucket.org/pypy/pypy/changeset/e556f833d5d4/
Log: OS/X fix.
diff --git a/pypy/module/pwd/test/test_pwd.py b/pypy/module/pwd/test/test_pwd.py
--- a/pypy/module/pwd/test/test_pwd.py
+++ b/pypy/module/pwd/test/test_pwd.py
@@ -5,14 +5,17 @@
cls.space = gettestobjspace(usemodules=['pwd'])
def test_getpwuid(self):
- import pwd
+ import pwd, sys
raises(KeyError, pwd.getpwuid, -1)
pw = pwd.getpwuid(0)
assert pw.pw_name == 'root'
assert isinstance(pw.pw_passwd, str)
assert pw.pw_uid == 0
assert pw.pw_gid == 0
- assert pw.pw_dir == '/root'
+ if sys.platform.startswith('linux'):
+ assert pw.pw_dir == '/root'
+ else:
+ assert pw.pw_dir.startswith('/')
assert pw.pw_shell.startswith('/')
#
assert type(pw.pw_uid) is int
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit