Skip to content

Commit 1f7a917

Browse files
committed
[test suite] add --skip-compile arg
1 parent 16825ab commit 1f7a917

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

test/run.py

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -70,11 +70,12 @@ def main():
7070
do_cmd("%s clone %s %s" % (cmds['git'],
7171
fwknop_codecov_dir, fwknop_afl_dir), None, cargs)
7272

73-
### build both fwknop repositories under the specified commit
74-
build_fwknop(fwknop_codecov_dir, fwknop_commit,
75-
fwknop_codecov_compile, cmds, cargs)
76-
build_fwknop(fwknop_afl_dir, fwknop_commit,
77-
fwknop_afl_compile, cmds, cargs)
73+
if not cargs.skip_compile:
74+
### build both fwknop repositories under the specified commit
75+
build_fwknop(fwknop_codecov_dir, fwknop_commit,
76+
fwknop_codecov_compile, cmds, cargs)
77+
build_fwknop(fwknop_afl_dir, fwknop_commit,
78+
fwknop_afl_compile, cmds, cargs)
7879

7980
### run the actual tests
8081
print "[+] Running afl-cov tests (ignore 'Terminated' messages)..."
@@ -137,6 +138,9 @@ def parse_cmdline():
137138
p.add_argument("--ignore-core-pattern", action='store_true',
138139
help="Ignore the /proc/sys/kernel/core_pattern setting in --live mode",
139140
default=False)
141+
p.add_argument("--skip-compile", action='store_true',
142+
help="Skip fwknop compilation (assumes it was already done from a previous run)",
143+
default=False)
140144
p.add_argument("-v", "--verbose", action='store_true',
141145
help="Verbose mode", default=False)
142146

0 commit comments

Comments
 (0)