diff tests/test_util.py @ 1363:3c213ca49f7e stable

tests: update for behavior change in subversion 1.9 In revision r1592724, subversion changed 'svn propget' when no properties are there to be an error. This is mildly annoying but oh well. We work around this to achieve the old behavior. I pity the scripts that relied on that behavior.
author Sean Farley <sean@farley.io>
date Thu, 29 Oct 2015 17:18:41 -0700
parents 38be7a6b6def
children 89997a5fc181
line wrap: on
line diff
--- a/tests/test_util.py
+++ b/tests/test_util.py
@@ -358,8 +358,12 @@ def svnpropget(repo_path, path, prop, re
                          stdout=subprocess.PIPE,
                          stderr=subprocess.STDOUT)
     stdout, stderr = p.communicate()
-    if p.returncode:
+    if p.returncode and stderr:
         raise Exception('svn ls failed on %s: %r' % (path, stderr))
+    if 'W200017' in stdout:
+        # subversion >= 1.9 changed 'no properties' to be an error, so let's
+        # avoid that
+        return ''
     return stdout.strip()