--- a/tests/test-check-py3-compat.t Thu Apr 14 00:49:58 2016 +0530
+++ b/tests/test-check-py3-compat.t Thu Apr 14 00:53:35 2016 +0530
@@ -67,7 +67,6 @@
tests/test-symlink-os-yes-fs-no.py not using absolute_import
tests/test-trusted.py requires print_function
tests/test-ui-color.py not using absolute_import
- tests/test-url.py not using absolute_import
#if py3exe
$ hg files 'set:(**.py)' | sed 's|\\|/|g' | xargs $PYTHON3 contrib/check-py3-compat.py
--- a/tests/test-url.py Thu Apr 14 00:49:58 2016 +0530
+++ b/tests/test-url.py Thu Apr 14 00:53:35 2016 +0530
@@ -1,4 +1,6 @@
-from __future__ import print_function
+from __future__ import absolute_import, print_function
+
+import doctest
import os
def check(a, b):
@@ -8,8 +10,11 @@
def cert(cn):
return {'subject': ((('commonName', cn),),)}
-from mercurial.sslutil import _verifycert
+from mercurial import (
+ sslutil,
+)
+_verifycert = sslutil._verifycert
# Test non-wildcard certificates
check(_verifycert(cert('example.com'), 'example.com'),
None)
@@ -58,8 +63,6 @@
check(_verifycert(cert(u'\u4f8b.jp'), 'example.jp'),
'IDN in certificate not supported')
-import doctest
-
def test_url():
"""
>>> from mercurial.util import url