@@ -196,6 +196,11 @@ def preprocess(test, params, env):
@param env: The environment (a dict-like object).
"""
error.context("preprocessing")
+
+ if params.get("bridge") == "private":
+ brcfg = virt_test_setup.PrivateBridgeConfig(params)
+ brcfg.setup()
+
# Start tcpdump if it isn't already running
if "address_cache" not in env:
env["address_cache"] = {}
@@ -365,6 +370,10 @@ def postprocess(test, params, env):
int(params.get("post_command_timeout", "600")),
params.get("post_command_noncritical") == "yes")
+ if params.get("bridge") == "private":
+ brcfg = virt_test_setup.PrivateBridgeConfig()
+ brcfg.cleanup()
+
def postprocess_on_error(test, params, env):
"""
Call bridge setup at preprocessing and cleanup at postprocessing. The bridge can be cleaned up when no tap interfaces are using it. Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com> --- client/virt/virt_env_process.py | 9 +++++++++ 1 files changed, 9 insertions(+), 0 deletions(-)