changeset 1508:5441a9d1fd50

test_push_command: avoid letting interface name in IPv6 address Subversion isn't a fan.
author Augie Fackler <raf@durin42.com>
date Mon, 29 May 2017 12:50:55 -0400
parents debba0fa822e
children 8c7dae2e0f54
files tests/test_push_command.py
diffstat 1 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/tests/test_push_command.py
+++ b/tests/test_push_command.py
@@ -157,6 +157,12 @@ class PushTests(test_util.TestBase):
         # If we're connecting via IPv6 the need to put brackets around the
         # hostname in the URL.
         ipv6 = selected[0] == socket.AF_INET6
+
+        # Ditch any interface information since that's not helpful in
+        # a URL
+        if ipv6 and ':' in self.host and '%' in self.host:
+            self.host = self.host.rsplit('%', 1)[0]
+
         urlfmt = 'svn://[%s]:%d/%s' if ipv6 else 'svn://%s:%d/%s'
 
         args = ['svnserve', '--daemon', '--foreground',