Skip to content

Commit

Permalink
change wait requirements
Browse files Browse the repository at this point in the history
  • Loading branch information
xansec committed Sep 25, 2024
1 parent e6bdd11 commit 2b3554e
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions mayhem/mayhem.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -360,10 +360,8 @@ def _mayhem_run_impl(ctx):
return_files = [mayhem_out]

if ctx.attr.wait:
if ctx.attr.dynamic or ctx.attr.all:
fail("The 'wait' attribute cannot be used with the 'dynamic' or 'all' attributes")
if not ctx.attr.duration and not ctx.attr.regression:
fail("The 'wait' attribute requires either the 'duration' attribute or 'regression' attribute to be set (otherwise, we will wait forever)")
if not ctx.attr.duration:
fail("The 'wait' attribute requires the 'duration' attribute to be set (otherwise, we will wait forever)")
else:
mayhem_out_wait = mayhem_wait(ctx, ctx.executable._mayhem_cli, mayhem_cli_exe, mayhem_out, is_windows, ctx.attr.fail_on_defects)
return_files.append(mayhem_out_wait)
Expand Down

0 comments on commit 2b3554e

Please sign in to comment.