subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1241709 - /subversion/trunk/subversion/bindings/swig/python/tests/client.py
Date Wed, 08 Feb 2012 00:05:48 GMT
Author: stsp
Date: Wed Feb  8 00:05:47 2012
New Revision: 1241709

URL: http://svn.apache.org/viewvc?rev=1241709&view=rev
Log:
Fix python bindings regression tests failures with Python < 2.7.

* subversion/bindings/swig/python/tests/client.py
  (testGnomeKeyring): Don't use an annotation (@unittest.skipUnless)
   which only exists in Python 2.7 and later. Just return early from
   the test if gnome-keyring support isn't available.
   It would be nice to actually skip tests but short of porting
   code from our cmdline test suite to the bindings there seems
   to be no good way of achieving this in Python 2.4.

Suggested by: gstein

Modified:
    subversion/trunk/subversion/bindings/swig/python/tests/client.py

Modified: subversion/trunk/subversion/bindings/swig/python/tests/client.py
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/swig/python/tests/client.py?rev=1241709&r1=1241708&r2=1241709&view=diff
==============================================================================
--- subversion/trunk/subversion/bindings/swig/python/tests/client.py (original)
+++ subversion/trunk/subversion/bindings/swig/python/tests/client.py Wed Feb  8 00:05:47 2012
@@ -379,9 +379,11 @@ class SubversionClientTestCase(unittest.
     # Not much more we can test in this minimal environment.
     self.assert_(isinstance(providers, list))
 
-  @unittest.skipUnless(hasattr(core, 'svn_auth_set_gnome_keyring_unlock_prompt_func'),
-                       "not supported on this platform")
   def testGnomeKeyring(self):
+    if not hasattr(core, 'svn_auth_set_gnome_keyring_unlock_prompt_func'):
+      # gnome-keying not compiled in, do nothing
+      return
+
     # This tests setting the gnome-keyring unlock prompt function as an
     # auth baton parameter. It doesn't actually call gnome-keyring
     # stuff, since that would require having a gnome-keyring running. We



Mime
View raw message