Multiple fixes to unwedge stable/mitaka
* Fix broken test with cmd2 0.7.0 Co-author: todd.leonhardt@gmail.com Closes-Bug: #1672108 (cherry picked from commit0d670bbcc7
) * pep8: fix F405 error cliff/argparse.py:9:26: F405 ArgumentParser may be undefined, or defined from star imports: argparse (cherry picked from commit1ecd63b7a7
) Change-Id: I4bb02749a8fafccaff4ef7ce94ff0c4910fb67e6
This commit is contained in:
parent
9c723c6f8f
commit
fdd87e0582
|
@ -6,7 +6,7 @@ import sys
|
|||
|
||||
|
||||
if sys.version_info < (3, 5):
|
||||
class ArgumentParser(ArgumentParser):
|
||||
class ArgumentParser(ArgumentParser): # noqa
|
||||
def __init__(self, *args, **kwargs):
|
||||
self.allow_abbrev = kwargs.pop("allow_abbrev", True)
|
||||
super(ArgumentParser, self).__init__(*args, **kwargs)
|
||||
|
|
|
@ -32,8 +32,8 @@ def test_no_completenames():
|
|||
|
||||
|
||||
def test_both_completenames():
|
||||
# cmd2.Cmd define do_hi and do_history methods
|
||||
_test_completenames(['hi', 'history', 'hips', 'hippo'], 'hi')
|
||||
# cmd2.Cmd defines do_history method
|
||||
_test_completenames(['history', 'hips', 'hippo'], 'hi')
|
||||
|
||||
|
||||
def _test_completedefault(expecteds, line, begidx):
|
||||
|
|
Loading…
Reference in New Issue