Skip to content

Commit 978b6d8

Browse files
pb8obchalios
authored andcommitted
fix(test): test_spectre_meltdown_checker_on_host when not running on PRs
Currently the test fails when running it outside of a PR, because the checker returns an exit code of 2. Fixes: f79d301 Signed-off-by: Pablo Barbáchano <[email protected]>
1 parent 7254a21 commit 978b6d8

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

tests/framework/ab_test.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,14 +115,15 @@ def git_ab_test_host_command_if_pr(
115115
command: str,
116116
*,
117117
comparator: Callable[[CommandReturn, CommandReturn], bool] = default_comparator,
118+
**kwargs,
118119
):
119120
"""Runs the given bash command as an A/B-Test if we're in a pull request context (asserting that its stdout and
120121
stderr did not change across the PR). Otherwise runs the command, asserting it returns a zero exit code
121122
"""
122123
if is_pr():
123124
git_ab_test_host_command(command, comparator=comparator)
124125
else:
125-
utils.run_cmd(command)
126+
utils.run_cmd(command, **kwargs)
126127

127128

128129
def git_ab_test_host_command(

tests/integration_tests/security/test_vulnerabilities.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,7 @@ def test_spectre_meltdown_checker_on_host(spectre_meltdown_checker):
180180
comparator=set_did_not_grow_comparator(
181181
spectre_meltdown_reported_vulnerablities
182182
),
183+
ignore_return_code=True,
183184
)
184185

185186

0 commit comments

Comments
 (0)