test ovs: Mark OVS tests xfail on AssertionError

In travis(Ubuntu host) with NM 1.20 on CentOS 8, the
`test_bridge_with_internal_interface` test case might fail on empty
internal interface.

Cannot reproduce this on RHEL 8.1 host with 300+ retry, so this might be
cause by the host OS kernel.

This patch expand the xfail range to cover AssertionError also.
We will eventually remove xfail for all OVS test case after apply fix or
workaround.

Signed-off-by: Gris Ge <fge@redhat.com>
This commit is contained in:
Gris Ge 2019-11-15 16:47:10 +08:00
parent 8cdaaa71c8
commit 6cc3d50dab
2 changed files with 14 additions and 7 deletions

View File

@ -53,7 +53,8 @@ def bridge_default_config():
@pytest.mark.xfail(
raises=MainloopTestError, reason='https://bugzilla.redhat.com/1724901'
raises=(MainloopTestError, AssertionError),
reason='https://bugzilla.redhat.com/1724901',
)
def test_create_and_remove_minimum_config_bridge(
bridge_minimum_config, bridge_default_config
@ -69,7 +70,8 @@ def test_create_and_remove_minimum_config_bridge(
@pytest.mark.xfail(
raises=MainloopTestError, reason='https://bugzilla.redhat.com/1724901'
raises=(MainloopTestError, AssertionError),
reason='https://bugzilla.redhat.com/1724901',
)
def test_bridge_with_system_port(eth1_up, bridge_default_config):
bridge_desired_state = bridge_default_config
@ -91,7 +93,8 @@ def test_bridge_with_system_port(eth1_up, bridge_default_config):
@pytest.mark.xfail(
raises=MainloopTestError, reason='https://bugzilla.redhat.com/1724901'
raises=(MainloopTestError, AssertionError),
reason='https://bugzilla.redhat.com/1724901',
)
def test_bridge_with_internal_interface(bridge_default_config):
bridge_desired_state = bridge_default_config

View File

@ -33,7 +33,8 @@ PORT1 = 'ovs1'
@pytest.mark.xfail(
raises=NmstateLibnmError, reason='https://bugzilla.redhat.com/1724901'
raises=(NmstateLibnmError, AssertionError),
reason='https://bugzilla.redhat.com/1724901',
)
def test_create_and_remove_ovs_bridge_with_min_desired_state():
with Bridge(BRIDGE1).create() as state:
@ -43,7 +44,8 @@ def test_create_and_remove_ovs_bridge_with_min_desired_state():
@pytest.mark.xfail(
raises=NmstateLibnmError, reason='https://bugzilla.redhat.com/1724901'
raises=(NmstateLibnmError, AssertionError),
reason='https://bugzilla.redhat.com/1724901',
)
def test_create_and_remove_ovs_bridge_options_specified():
bridge = Bridge(BRIDGE1)
@ -63,7 +65,8 @@ def test_create_and_remove_ovs_bridge_options_specified():
@pytest.mark.xfail(
raises=NmstateLibnmError, reason='https://bugzilla.redhat.com/1724901'
raises=(NmstateLibnmError, AssertionError),
reason='https://bugzilla.redhat.com/1724901',
)
def test_create_and_remove_ovs_bridge_with_a_system_port(port0_up):
bridge = Bridge(BRIDGE1)
@ -77,7 +80,8 @@ def test_create_and_remove_ovs_bridge_with_a_system_port(port0_up):
@pytest.mark.xfail(
raises=NmstateLibnmError, reason='https://bugzilla.redhat.com/1724901'
raises=(NmstateLibnmError, AssertionError),
reason='https://bugzilla.redhat.com/1724901',
)
def test_create_and_remove_ovs_bridge_with_internal_port_and_static_ip():
bridge = Bridge(BRIDGE1)