Author: Armin Rigo <[email protected]>
Branch: 
Changeset: r57242:a65ca3de676a
Date: 2012-09-08 11:23 +0200
http://bitbucket.org/pypy/pypy/changeset/a65ca3de676a/

Log:    Blind attempt to fix issue1244.

diff --git a/pypy/module/_winreg/test/test_winreg.py 
b/pypy/module/_winreg/test/test_winreg.py
--- a/pypy/module/_winreg/test/test_winreg.py
+++ b/pypy/module/_winreg/test/test_winreg.py
@@ -221,7 +221,14 @@
 
     def test_dynamic_key(self):
         from _winreg import EnumValue, QueryValueEx, HKEY_PERFORMANCE_DATA
-        EnumValue(HKEY_PERFORMANCE_DATA, 0)
+        try:
+            EnumValue(HKEY_PERFORMANCE_DATA, 0)
+        except WindowsError, e:
+            import errno
+            if e.errno in (errno.EPERM, errno.EACCES):
+                skip("access denied to registry key "
+                     "(are you running in a non-interactive session?)")
+            raise
         QueryValueEx(HKEY_PERFORMANCE_DATA, None)
 
     def test_reflection_unsupported(self):
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to