diff options
author | Guanzhong Chen <gzchen@google.com> | 2019-08-15 10:38:09 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-08-15 10:38:09 -0700 |
commit | dcaa42c6bcad851faf4af8076e2f301ddddd6f21 (patch) | |
tree | ef0047a56bd969ce1159d9d24f057874dfa70888 /test/run-roundtrip.py | |
parent | 3150801f60bd64280fe43fdf4604c50018949eb9 (diff) | |
download | wabt-dcaa42c6bcad851faf4af8076e2f301ddddd6f21.tar.gz wabt-dcaa42c6bcad851faf4af8076e2f301ddddd6f21.tar.bz2 wabt-dcaa42c6bcad851faf4af8076e2f301ddddd6f21.zip |
Run flake8 on the whole repository (#1144)
Diffstat (limited to 'test/run-roundtrip.py')
-rwxr-xr-x | test/run-roundtrip.py | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/test/run-roundtrip.py b/test/run-roundtrip.py index 6b66ed7c..e64febe8 100755 --- a/test/run-roundtrip.py +++ b/test/run-roundtrip.py @@ -18,10 +18,7 @@ import argparse import difflib import os -import re -import shutil import sys -import tempfile import find_exe import utils @@ -65,7 +62,7 @@ def TwoRoundtrips(wat2wasm, wasm2wat, out_dir, filename, verbose): wasm3_file = os.path.join(out_dir, basename_noext + '-3.wasm') try: wat2wasm.RunWithArgs('-o', wasm1_file, filename) - except Error as e: + except Error: # if the file doesn't parse properly, just skip it (it may be a "bad-*" # test) return (SKIPPED, None) @@ -83,7 +80,7 @@ def OneRoundtripToStdout(wat2wasm, wasm2wat, out_dir, filename, verbose): wasm_file = os.path.join(out_dir, basename_noext + '.wasm') try: wat2wasm.RunWithArgs('-o', wasm_file, filename) - except Error as e: + except Error: # if the file doesn't parse properly, just skip it (it may be a "bad-*" # test) return (SKIPPED, None) @@ -106,8 +103,8 @@ def main(args): parser.add_argument('--stdout', action='store_true', help='do one roundtrip and write wast output to stdout') parser.add_argument('--no-error-cmdline', - help='don\'t display the subprocess\'s commandline when' - + ' an error occurs', dest='error_cmdline', + help='don\'t display the subprocess\'s commandline when ' + 'an error occurs', dest='error_cmdline', action='store_false') parser.add_argument('-p', '--print-cmd', help='print the commands that are run.', |