diff options
author | Chandan Singh <csingh43@bloomberg.net> | 2019-03-01 18:39:24 +0000 |
---|---|---|
committer | Chandan Singh <csingh43@bloomberg.net> | 2019-03-01 18:39:24 +0000 |
commit | 8c03feba913b2239296df184bcfd26d386cd1eec (patch) | |
tree | cf5f13982a4ef6365aff6f9c579033fd00156824 | |
parent | 1eba1fed210d9814a06ef2b9a24610132b18235c (diff) | |
download | buildstream-chandan/remove-redundant-pytest-mark.tar.gz |
tests: Remove redundant integration pytest markerschandan/remove-redundant-pytest-mark
Remove `pytest.mark.integration` for individual tests that already
include it in `pytestmarker` at the top.
FWIW the list of such files was found using:
git grep --name-only 'pytestmark = pytest.mark.integration' | xargs grep '@pytest.mark.integration'
-rw-r--r-- | tests/integration/artifact.py | 1 | ||||
-rw-r--r-- | tests/integration/autotools.py | 2 | ||||
-rw-r--r-- | tests/integration/make.py | 1 | ||||
-rw-r--r-- | tests/integration/messages.py | 2 | ||||
-rw-r--r-- | tests/integration/sandbox-bwrap.py | 2 | ||||
-rw-r--r-- | tests/integration/shell.py | 1 | ||||
-rw-r--r-- | tests/integration/workspace.py | 6 |
7 files changed, 0 insertions, 15 deletions
diff --git a/tests/integration/artifact.py b/tests/integration/artifact.py index 58e58bdcf..4a1b5768e 100644 --- a/tests/integration/artifact.py +++ b/tests/integration/artifact.py @@ -44,7 +44,6 @@ DATA_DIR = os.path.join( # A test to capture the integration of the cachebuildtrees # behaviour, which by default is to include the buildtree # content of an element on caching. -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_cache_buildtrees(cli, tmpdir, datafiles): diff --git a/tests/integration/autotools.py b/tests/integration/autotools.py index 3ed0533cf..2f8b46b16 100644 --- a/tests/integration/autotools.py +++ b/tests/integration/autotools.py @@ -17,7 +17,6 @@ DATA_DIR = os.path.join( # Test that an autotools build 'works' - we use the autotools sample # amhello project for this. -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_autotools_build(cli, tmpdir, datafiles): @@ -40,7 +39,6 @@ def test_autotools_build(cli, tmpdir, datafiles): # Test that an autotools build 'works' - we use the autotools sample # amhello project for this. -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_autotools_confroot_build(cli, tmpdir, datafiles): diff --git a/tests/integration/make.py b/tests/integration/make.py index a76fe9a41..9822600af 100644 --- a/tests/integration/make.py +++ b/tests/integration/make.py @@ -17,7 +17,6 @@ DATA_DIR = os.path.join( # Test that a make build 'works' - we use the make sample # makehello project for this. -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_make_build(cli, tmpdir, datafiles): diff --git a/tests/integration/messages.py b/tests/integration/messages.py index 7f4194e0f..96615eaa0 100644 --- a/tests/integration/messages.py +++ b/tests/integration/messages.py @@ -36,7 +36,6 @@ DATA_DIR = os.path.join( ) -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_disable_message_lines(cli, tmpdir, datafiles): @@ -72,7 +71,6 @@ def test_disable_message_lines(cli, tmpdir, datafiles): assert "Message contains " not in result.stderr -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_disable_error_lines(cli, tmpdir, datafiles): diff --git a/tests/integration/sandbox-bwrap.py b/tests/integration/sandbox-bwrap.py index 2c939e9be..a5cb92d62 100644 --- a/tests/integration/sandbox-bwrap.py +++ b/tests/integration/sandbox-bwrap.py @@ -20,7 +20,6 @@ DATA_DIR = os.path.join( # Bubblewrap sandbox doesn't remove the dirs it created during its execution, # so BuildStream tries to remove them to do good. BuildStream should be extra # careful when those folders already exist and should not touch them, though. -@pytest.mark.integration @pytest.mark.skipif(not HAVE_BWRAP, reason='Only available with bubblewrap') @pytest.mark.datafiles(DATA_DIR) def test_sandbox_bwrap_cleanup_build(cli, tmpdir, datafiles): @@ -44,7 +43,6 @@ def test_sandbox_bwrap_distinguish_setup_error(cli, tmpdir, datafiles): result.assert_task_error(error_domain=ErrorDomain.SANDBOX, error_reason="bwrap-sandbox-fail") -@pytest.mark.integration @pytest.mark.skipif(not HAVE_BWRAP, reason='Only available with bubblewrap') @pytest.mark.datafiles(DATA_DIR) def test_sandbox_bwrap_return_subprocess(cli, tmpdir, datafiles): diff --git a/tests/integration/shell.py b/tests/integration/shell.py index 97c4d0cad..7b89614d2 100644 --- a/tests/integration/shell.py +++ b/tests/integration/shell.py @@ -282,7 +282,6 @@ def test_cli_mount(cli, tmpdir, datafiles, path): # Test that we can see the workspace files in a shell -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_workspace_visible(cli, tmpdir, datafiles): diff --git a/tests/integration/workspace.py b/tests/integration/workspace.py index f1d8d6fcd..1f74eb718 100644 --- a/tests/integration/workspace.py +++ b/tests/integration/workspace.py @@ -16,7 +16,6 @@ DATA_DIR = os.path.join( ) -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_workspace_mount(cli, tmpdir, datafiles): @@ -33,7 +32,6 @@ def test_workspace_mount(cli, tmpdir, datafiles): assert os.path.exists(os.path.join(cli.directory, 'workspace')) -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_workspace_commanddir(cli, tmpdir, datafiles): @@ -51,7 +49,6 @@ def test_workspace_commanddir(cli, tmpdir, datafiles): assert os.path.exists(os.path.join(cli.directory, 'workspace', 'build')) -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_workspace_updated_dependency(cli, tmpdir, datafiles): @@ -106,7 +103,6 @@ def test_workspace_updated_dependency(cli, tmpdir, datafiles): assert res.output == 'Hello china!\n\n' -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_workspace_update_dependency_failed(cli, tmpdir, datafiles): @@ -182,7 +178,6 @@ def test_workspace_update_dependency_failed(cli, tmpdir, datafiles): assert res.output == 'Hello world!\nHello spain!\n\n' -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_updated_dependency_nested(cli, tmpdir, datafiles): @@ -236,7 +231,6 @@ def test_updated_dependency_nested(cli, tmpdir, datafiles): assert res.output == 'Hello world!\nHello test!\n\n' -@pytest.mark.integration @pytest.mark.datafiles(DATA_DIR) @pytest.mark.skipif(not HAVE_SANDBOX, reason='Only available with a functioning sandbox') def test_incremental_configure_commands_run_only_once(cli, tmpdir, datafiles): |