Correct some flake8 bits
This commit is contained in:
parent
80190b203c
commit
eadd3918f1
@ -226,8 +226,7 @@ _MIGRATOR_TESTS = (
|
|||||||
\t"gopkg.in/urfave/cli.v2"
|
\t"gopkg.in/urfave/cli.v2"
|
||||||
\t"gopkg.in/urfave/cli.v2"
|
\t"gopkg.in/urfave/cli.v2"
|
||||||
\t"gopkg.in/urfave/cli.v2"
|
\t"gopkg.in/urfave/cli.v2"
|
||||||
"""
|
""")
|
||||||
)
|
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
12
runtests
12
runtests
@ -18,11 +18,11 @@ _TARGETS = {}
|
|||||||
def main(sysargs=sys.argv[:]):
|
def main(sysargs=sys.argv[:]):
|
||||||
parser = argparse.ArgumentParser()
|
parser = argparse.ArgumentParser()
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
'target', nargs='?', choices=tuple(targets.keys()), default='test'
|
'target', nargs='?', choices=tuple(_TARGETS.keys()), default='test'
|
||||||
)
|
)
|
||||||
args = parser.parse_args(sysargs[1:])
|
args = parser.parse_args(sysargs[1:])
|
||||||
|
|
||||||
targets[args.target]()
|
_TARGETS[args.target]()
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
|
|
||||||
@ -65,14 +65,6 @@ def _vet():
|
|||||||
_run('go vet ./...'.split())
|
_run('go vet ./...'.split())
|
||||||
|
|
||||||
|
|
||||||
@_target
|
|
||||||
def _migrator():
|
|
||||||
exe = os.path.join(
|
|
||||||
os.path.abspath(os.path.dirname(__file__)), 'cli-v1-to-v2'
|
|
||||||
)
|
|
||||||
run(['py.test', exe])
|
|
||||||
|
|
||||||
|
|
||||||
def _run(command):
|
def _run(command):
|
||||||
print('runtests: {}'.format(' '.join(command)), file=sys.stderr)
|
print('runtests: {}'.format(' '.join(command)), file=sys.stderr)
|
||||||
check_call(command)
|
check_call(command)
|
||||||
|
Loading…
Reference in New Issue
Block a user