mirror of
https://github.com/openSUSE/osc.git
synced 2024-12-26 01:46:13 +01:00
behave: Remove InsecureRequestWarning that is irrelevant to the tests from stderr
This commit is contained in:
parent
3faf01c862
commit
6394867952
@ -1,4 +1,5 @@
|
|||||||
import os
|
import os
|
||||||
|
import re
|
||||||
import shutil
|
import shutil
|
||||||
import tempfile
|
import tempfile
|
||||||
import time
|
import time
|
||||||
@ -54,6 +55,8 @@ def step_impl(context, args):
|
|||||||
cmd = context.osc.get_cmd() + [args]
|
cmd = context.osc.get_cmd() + [args]
|
||||||
cmd = " ".join(cmd)
|
cmd = " ".join(cmd)
|
||||||
run_in_context(context, cmd, can_fail=True)
|
run_in_context(context, cmd, can_fail=True)
|
||||||
|
# remove InsecureRequestWarning that is irrelevant to the tests
|
||||||
|
context.cmd_stderr = re.sub(r"^.*InsecureRequestWarning.*\n warnings.warn\(\n", "", context.cmd_stderr)
|
||||||
|
|
||||||
|
|
||||||
@behave.step('I wait for osc results for "{project}" "{package}"')
|
@behave.step('I wait for osc results for "{project}" "{package}"')
|
||||||
|
Loading…
Reference in New Issue
Block a user