diff options
Diffstat (limited to 'test/py')
-rw-r--r-- | test/py/conftest.py | 10 | ||||
-rw-r--r-- | test/py/tests/test_efi_loader.py | 2 | ||||
-rw-r--r-- | test/py/tests/test_fpga.py | 4 | ||||
-rw-r--r-- | test/py/tests/test_net.py | 2 |
4 files changed, 11 insertions, 7 deletions
diff --git a/test/py/conftest.py b/test/py/conftest.py index 5aea85647af..6c3ac67979a 100644 --- a/test/py/conftest.py +++ b/test/py/conftest.py @@ -711,9 +711,13 @@ def setup_buildconfigspec(item): """ for options in item.iter_markers('buildconfigspec'): - option = options.args[0] - if not ubconfig.buildconfig.get('config_' + option.lower(), None): - pytest.skip('.config feature "%s" not enabled' % option.lower()) + nomatch = True + for arg in options.args: + if ubconfig.buildconfig.get('config_' + arg.lower(), None): + nomatch = False + if nomatch: + argsString = ', '.join(options.args) + pytest.skip(f'.config features "{argsString}" not enabled') for options in item.iter_markers('notbuildconfigspec'): option = options.args[0] if ubconfig.buildconfig.get('config_' + option.lower(), None): diff --git a/test/py/tests/test_efi_loader.py b/test/py/tests/test_efi_loader.py index 91f151d09cd..dc58c0d4dbd 100644 --- a/test/py/tests/test_efi_loader.py +++ b/test/py/tests/test_efi_loader.py @@ -98,7 +98,7 @@ def test_efi_setup_dhcp(ubman): global net_set_up net_set_up = True -@pytest.mark.buildconfigspec('net') +@pytest.mark.buildconfigspec('net', 'net_lwip') def test_efi_setup_static(ubman): """Set up the network using a static IP configuration. diff --git a/test/py/tests/test_fpga.py b/test/py/tests/test_fpga.py index 74cd42b910e..299a8653f74 100644 --- a/test/py/tests/test_fpga.py +++ b/test/py/tests/test_fpga.py @@ -506,7 +506,7 @@ def test_fpga_loadfs(ubman): @pytest.mark.buildconfigspec('cmd_fpga_load_secure') @pytest.mark.buildconfigspec('cmd_net') @pytest.mark.buildconfigspec('cmd_dhcp') -@pytest.mark.buildconfigspec('net') +@pytest.mark.buildconfigspec('net', 'net_lwip') def test_fpga_secure_bit_auth(ubman): test_net.test_net_dhcp(ubman) @@ -534,7 +534,7 @@ def test_fpga_secure_bit_auth(ubman): @pytest.mark.buildconfigspec('cmd_fpga_load_secure') @pytest.mark.buildconfigspec('cmd_net') @pytest.mark.buildconfigspec('cmd_dhcp') -@pytest.mark.buildconfigspec('net') +@pytest.mark.buildconfigspec('net', 'net_lwip') def test_fpga_secure_bit_img_auth_kup(ubman): test_net.test_net_dhcp(ubman) diff --git a/test/py/tests/test_net.py b/test/py/tests/test_net.py index 27cdd73fd49..6ef02e53389 100644 --- a/test/py/tests/test_net.py +++ b/test/py/tests/test_net.py @@ -201,7 +201,7 @@ def test_net_dhcp6(ubman): global net6_set_up net6_set_up = True -@pytest.mark.buildconfigspec('net') +@pytest.mark.buildconfigspec('net', 'net_lwip') def test_net_setup_static(ubman): """Set up a static IP configuration. |