py3: replace str(None) with literal in convcmd.py
authorYuya Nishihara <yuya@tcha.org>
Wed, 27 Sep 2017 19:08:23 +0900
changeset 34359 ee10eb665036
parent 34358 8cbcee0b923d
child 34360 f435097d13c9
py3: replace str(None) with literal in convcmd.py
hgext/convert/convcmd.py
tests/test-doctest.py
--- a/hgext/convert/convcmd.py	Wed Sep 27 19:04:32 2017 +0900
+++ b/hgext/convert/convcmd.py	Wed Sep 27 19:08:23 2017 +0900
@@ -87,7 +87,7 @@
     # At some point we used "None" literal to denote the default branch,
     # attempt to use that for backward compatibility.
     if (not branch):
-        branch = branchmap.get(str(None), branch)
+        branch = branchmap.get('None', branch)
     return branch
 
 source_converters = [
--- a/tests/test-doctest.py	Wed Sep 27 19:04:32 2017 +0900
+++ b/tests/test-doctest.py	Wed Sep 27 19:08:23 2017 +0900
@@ -71,7 +71,7 @@
 testmod('mercurial.url')
 testmod('mercurial.util', py3=False)  # py3: multiple bytes/unicode issues
 testmod('mercurial.util', testtarget='platform')
-testmod('hgext.convert.convcmd', py3=False)  # py3: use of str() ?
+testmod('hgext.convert.convcmd')
 testmod('hgext.convert.cvsps')
 testmod('hgext.convert.filemap')
 testmod('hgext.convert.p4')