Benjamin Schubert pushed to branch bschubert/add-fedora-nobwrap-tests at BuildStream / buildstream
Commits:
- 
9fa8a881
by James Ennis at 2018-11-20T17:00:42Z
- 
fb8860db
by Jürg Billeter at 2018-11-20T17:32:58Z
- 
87751350
by Benjamin Schubert at 2018-11-20T18:10:48Z
- 
8668df9f
by Benjamin Schubert at 2018-11-20T18:10:48Z
- 
cc6a7f0d
by Benjamin Schubert at 2018-11-20T18:10:48Z
- 
eb37dd89
by Benjamin Schubert at 2018-11-20T18:10:48Z
- 
e030b48e
by Benjamin Schubert at 2018-11-20T18:10:48Z
- 
57e6358f
by Benjamin Schubert at 2018-11-20T18:10:48Z
- 
e70dd1f8
by Benjamin Schubert at 2018-11-20T18:10:48Z
- 
f7cb4386
by Benjamin Schubert at 2018-11-20T18:10:48Z
26 changed files:
- .gitlab-ci.yml
- buildstream/_yaml.py
- tests/examples/autotools.py
- tests/examples/developing.py
- tests/examples/flatpak-autotools.py
- tests/examples/integration-commands.py
- tests/examples/junctions.py
- tests/examples/running-commands.py
- tests/integration/autotools.py
- tests/integration/build-tree.py
- tests/integration/build-uid.py
- tests/integration/cachedfail.py
- tests/integration/cmake.py
- tests/integration/compose.py
- tests/integration/make.py
- tests/integration/manual.py
- tests/integration/pip_element.py
- tests/integration/pip_source.py
- tests/integration/pullbuildtrees.py
- tests/integration/script.py
- tests/integration/shell.py
- tests/integration/sockets.py
- tests/integration/source-determinism.py
- tests/integration/stack.py
- tests/integration/symlinks.py
- tests/integration/workspace.py
Changes:
| ... | ... | @@ -10,6 +10,11 @@ stages: | 
| 10 | 10 |    - test
 | 
| 11 | 11 |    - post
 | 
| 12 | 12 |  | 
| 13 | +variables:
 | |
| 14 | +  PYTEST_ADDOPTS: "--color=yes"
 | |
| 15 | +  INTEGRATION_CACHE: "${CI_PROJECT_DIR}/cache/integration-cache"
 | |
| 16 | +  TEST_COMMAND: 'python3 setup.py test --index-url invalid://uri --addopts --integration'
 | |
| 17 | + | |
| 13 | 18 |  #####################################################
 | 
| 14 | 19 |  #                  Prepare stage                    #
 | 
| 15 | 20 |  #####################################################
 | 
| ... | ... | @@ -52,66 +57,63 @@ source_dist: | 
| 52 | 57 |  | 
| 53 | 58 |  # Run premerge commits
 | 
| 54 | 59 |  #
 | 
| 55 | -.linux-tests-template: &linux-tests
 | |
| 60 | +.tests-template: &tests
 | |
| 56 | 61 |    stage: test
 | 
| 62 | + | |
| 57 | 63 |    variables:
 | 
| 58 | -    PYTEST_ADDOPTS: "--color=yes"
 | |
| 59 | -  script:
 | |
| 64 | +    COVERAGE_DIR: coverage-linux
 | |
| 65 | + | |
| 66 | +  before_script:
 | |
| 60 | 67 |    # Diagnostics
 | 
| 61 | 68 |    - mount
 | 
| 62 | 69 |    - df -h
 | 
| 63 | 70 |  | 
| 64 | -  - useradd -Um buildstream
 | |
| 65 | -  - chown -R buildstream:buildstream .
 | |
| 66 | - | |
| 67 | -  - export INTEGRATION_CACHE="$(pwd)/cache/integration-cache"
 | |
| 68 | - | |
| 69 | -  # Unpack and get into dist/buildstream
 | |
| 71 | +  # Unpack
 | |
| 70 | 72 |    - cd dist && ./unpack.sh
 | 
| 71 | -  - chown -R buildstream:buildstream buildstream
 | |
| 72 | 73 |    - cd buildstream
 | 
| 73 | 74 |  | 
| 75 | +  script:
 | |
| 76 | +  - useradd -Um buildstream
 | |
| 77 | +  - chown -R buildstream:buildstream .
 | |
| 78 | + | |
| 74 | 79 |    # Run the tests from the source distribution, We run as a simple
 | 
| 75 | 80 |    # user to test for permission issues
 | 
| 76 | -  - su buildstream -c 'python3 setup.py test --index-url invalid://uri --addopts --integration'
 | |
| 81 | +  - su buildstream -c "${TEST_COMMAND}"
 | |
| 77 | 82 |  | 
| 78 | -  # Go back to the toplevel and collect our reports
 | |
| 79 | -  - cd ../..
 | |
| 80 | -  - mkdir -p coverage-linux/
 | |
| 81 | -  - cp dist/buildstream/.coverage coverage-linux/coverage."${CI_JOB_NAME}"
 | |
| 83 | +  after_script:
 | |
| 84 | +  # Collect our reports
 | |
| 85 | +  - mkdir -p ${COVERAGE_DIR}
 | |
| 86 | +  - cp dist/buildstream/.coverage ${COVERAGE_DIR}/coverage."${CI_JOB_NAME}"
 | |
| 87 | +  except:
 | |
| 88 | +  - schedules
 | |
| 82 | 89 |    artifacts:
 | 
| 83 | 90 |      paths:
 | 
| 84 | -    - coverage-linux/
 | |
| 91 | +    - ${COVERAGE_DIR}
 | |
| 85 | 92 |  | 
| 86 | 93 |  tests-debian-9:
 | 
| 87 | 94 |    image: buildstream/testsuite-debian:9-master-123-7ce6581b
 | 
| 88 | -  <<: *linux-tests
 | |
| 89 | -  except:
 | |
| 90 | -  - schedules
 | |
| 95 | +  <<: *tests
 | |
| 91 | 96 |  | 
| 92 | 97 |  tests-fedora-27:
 | 
| 93 | 98 |    image: buildstream/testsuite-fedora:27-master-123-7ce6581b
 | 
| 94 | -  <<: *linux-tests
 | |
| 95 | -  except:
 | |
| 96 | -  - schedules
 | |
| 99 | +  <<: *tests
 | |
| 97 | 100 |  | 
| 98 | 101 |  tests-fedora-28:
 | 
| 99 | 102 |    image: buildstream/testsuite-fedora:28-master-123-7ce6581b
 | 
| 100 | -  <<: *linux-tests
 | |
| 101 | -  except:
 | |
| 102 | -  - schedules
 | |
| 103 | +  <<: *tests
 | |
| 103 | 104 |  | 
| 104 | 105 |  tests-ubuntu-18.04:
 | 
| 105 | 106 |    image: buildstream/testsuite-ubuntu:18.04-master-123-7ce6581b
 | 
| 106 | -  <<: *linux-tests
 | |
| 107 | -  except:
 | |
| 108 | -  - schedules
 | |
| 107 | +  <<: *tests
 | |
| 109 | 108 |  | 
| 110 | 109 |  overnight-fedora-28-aarch64:
 | 
| 111 | 110 |    image: buildstream/testsuite-fedora:aarch64-28-master-123-7ce6581b
 | 
| 112 | 111 |    tags:
 | 
| 113 | 112 |      - aarch64
 | 
| 114 | -  <<: *linux-tests
 | |
| 113 | +  <<: *tests
 | |
| 114 | +  # We need to override the exclusion from the template
 | |
| 115 | +  # in order to run on schedules
 | |
| 116 | +  except: []
 | |
| 115 | 117 |    only:
 | 
| 116 | 118 |    - schedules
 | 
| 117 | 119 |  | 
| ... | ... | @@ -119,13 +121,12 @@ tests-unix: | 
| 119 | 121 |    # Use fedora here, to a) run a test on fedora and b) ensure that we
 | 
| 120 | 122 |    # can get rid of ostree - this is not possible with debian-8
 | 
| 121 | 123 |    image: buildstream/testsuite-fedora:27-master-123-7ce6581b
 | 
| 122 | -  stage: test
 | |
| 124 | +  <<: *tests
 | |
| 123 | 125 |    variables:
 | 
| 124 | 126 |      BST_FORCE_BACKEND: "unix"
 | 
| 125 | -    PYTEST_ADDOPTS: "--color=yes"
 | |
| 126 | -  script:
 | |
| 127 | +    COVERAGE_DIR: coverage-unix
 | |
| 127 | 128 |  | 
| 128 | -    - export INTEGRATION_CACHE="$(pwd)/cache/integration-cache"
 | |
| 129 | +  script:
 | |
| 129 | 130 |  | 
| 130 | 131 |      # We remove the Bubblewrap and OSTree packages here so that we catch any
 | 
| 131 | 132 |      # codepaths that try to use them. Removing OSTree causes fuse-libs to
 | 
| ... | ... | @@ -133,22 +134,26 @@ tests-unix: | 
| 133 | 134 |      - dnf mark install fuse-libs
 | 
| 134 | 135 |      - dnf erase -y bubblewrap ostree
 | 
| 135 | 136 |  | 
| 136 | -    # Unpack and get into dist/buildstream
 | |
| 137 | -    - cd dist && ./unpack.sh && cd buildstream
 | |
| 138 | - | |
| 139 | 137 |      # Since the unix platform is required to run as root, no user change required
 | 
| 140 | -    - python3 setup.py test --index-url invalid://uri --addopts --integration
 | |
| 138 | +    - ${TEST_COMMAND}
 | |
| 141 | 139 |  | 
| 142 | -    # Go back to the toplevel and collect our reports
 | |
| 143 | -    - cd ../..
 | |
| 144 | -    - mkdir -p coverage-unix/
 | |
| 145 | -    - cp dist/buildstream/.coverage coverage-unix/coverage.unix
 | |
| 146 | -  except:
 | |
| 147 | -  - schedules
 | |
| 148 | -  artifacts:
 | |
| 149 | -    paths:
 | |
| 150 | -    - coverage-unix/
 | |
| 151 | -    - logs-unix/
 | |
| 140 | + | |
| 141 | +tests-fedora-missing-deps:
 | |
| 142 | +  # Ensure that tests behave nicely while missing bwrap and ostree
 | |
| 143 | +  image: buildstream/testsuite-fedora:28-master-119-552f5fc6
 | |
| 144 | +  <<: *tests
 | |
| 145 | + | |
| 146 | +  script:
 | |
| 147 | +    # We remove the Bubblewrap and OSTree packages here so that we catch any
 | |
| 148 | +    # codepaths that try to use them. Removing OSTree causes fuse-libs to
 | |
| 149 | +    # disappear unless we mark it as user-installed.
 | |
| 150 | +    - dnf mark install fuse-libs
 | |
| 151 | +    - dnf erase -y bubblewrap ostree
 | |
| 152 | + | |
| 153 | +    - useradd -Um buildstream
 | |
| 154 | +    - chown -R buildstream:buildstream .
 | |
| 155 | + | |
| 156 | +    - ${TEST_COMMAND}
 | |
| 152 | 157 |  | 
| 153 | 158 |  | 
| 154 | 159 |  # Automatically build documentation for every commit, we want to know
 | 
| ... | ... | @@ -273,7 +278,7 @@ coverage: | 
| 273 | 278 |      - pip3 install --no-index .
 | 
| 274 | 279 |      - mkdir report
 | 
| 275 | 280 |      - cd report
 | 
| 276 | -    - cp ../../../coverage-unix/coverage.unix .
 | |
| 281 | +    - cp ../../../coverage-unix/coverage.* .
 | |
| 277 | 282 |      - cp ../../../coverage-linux/coverage.* .
 | 
| 278 | 283 |      - ls coverage.*
 | 
| 279 | 284 |      - coverage combine --rcfile=../.coveragerc -a coverage.*
 | 
| ... | ... | @@ -476,12 +476,18 @@ def node_get_project_path(node, key, project_dir, *, | 
| 476 | 476 |      is_inside = project_dir_path.resolve() in full_resolved_path.parents or (
 | 
| 477 | 477 |          full_resolved_path == project_dir_path)
 | 
| 478 | 478 |  | 
| 479 | -    if path.is_absolute() or not is_inside:
 | |
| 479 | +    if not is_inside:
 | |
| 480 | 480 |          raise LoadError(LoadErrorReason.PROJ_PATH_INVALID,
 | 
| 481 | 481 |                          "{}: Specified path '{}' must not lead outside of the "
 | 
| 482 | 482 |                          "project directory"
 | 
| 483 | 483 |                          .format(provenance, path_str))
 | 
| 484 | 484 |  | 
| 485 | +    if path.is_absolute():
 | |
| 486 | +        raise LoadError(LoadErrorReason.PROJ_PATH_INVALID,
 | |
| 487 | +                        "{}: Absolute path: '{}' invalid.\n"
 | |
| 488 | +                        "Please specify a path relative to the project's root."
 | |
| 489 | +                        .format(provenance, path))
 | |
| 490 | + | |
| 485 | 491 |      if full_resolved_path.is_socket() or (
 | 
| 486 | 492 |              full_resolved_path.is_fifo() or
 | 
| 487 | 493 |              full_resolved_path.is_block_device()):
 | 
| ... | ... | @@ -3,7 +3,7 @@ import pytest | 
| 3 | 3 |  | 
| 4 | 4 |  from tests.testutils import cli_integration as cli
 | 
| 5 | 5 |  from tests.testutils.integration import assert_contains
 | 
| 6 | -from tests.testutils.site import IS_LINUX, MACHINE_ARCH
 | |
| 6 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX, MACHINE_ARCH
 | |
| 7 | 7 |  | 
| 8 | 8 |  pytestmark = pytest.mark.integration
 | 
| 9 | 9 |  | 
| ... | ... | @@ -15,7 +15,7 @@ DATA_DIR = os.path.join( | 
| 15 | 15 |  # Tests a build of the autotools amhello project on a alpine-linux base runtime
 | 
| 16 | 16 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 17 | 17 |                      reason='Examples are writtent for x86_64')
 | 
| 18 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 18 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 19 | 19 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 20 | 20 |  def test_autotools_build(cli, tmpdir, datafiles):
 | 
| 21 | 21 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -40,7 +40,7 @@ def test_autotools_build(cli, tmpdir, datafiles): | 
| 40 | 40 |  # Test running an executable built with autotools.
 | 
| 41 | 41 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 42 | 42 |                      reason='Examples are writtent for x86_64')
 | 
| 43 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 43 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 44 | 44 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 45 | 45 |  def test_autotools_run(cli, tmpdir, datafiles):
 | 
| 46 | 46 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -4,7 +4,7 @@ import pytest | 
| 4 | 4 |  import tests.testutils.patch as patch
 | 
| 5 | 5 |  from tests.testutils import cli_integration as cli
 | 
| 6 | 6 |  from tests.testutils.integration import assert_contains
 | 
| 7 | -from tests.testutils.site import IS_LINUX, MACHINE_ARCH
 | |
| 7 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX, MACHINE_ARCH
 | |
| 8 | 8 |  | 
| 9 | 9 |  pytestmark = pytest.mark.integration
 | 
| 10 | 10 |  | 
| ... | ... | @@ -16,7 +16,7 @@ DATA_DIR = os.path.join( | 
| 16 | 16 |  # Test that the project builds successfully
 | 
| 17 | 17 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 18 | 18 |                      reason='Examples are writtent for x86_64')
 | 
| 19 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 19 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 20 | 20 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 21 | 21 |  def test_autotools_build(cli, tmpdir, datafiles):
 | 
| 22 | 22 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -39,7 +39,7 @@ def test_autotools_build(cli, tmpdir, datafiles): | 
| 39 | 39 |  # Test the unmodified hello command works as expected.
 | 
| 40 | 40 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 41 | 41 |                      reason='Examples are writtent for x86_64')
 | 
| 42 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 42 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 43 | 43 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 44 | 44 |  def test_run_unmodified_hello(cli, tmpdir, datafiles):
 | 
| 45 | 45 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -72,7 +72,7 @@ def test_open_workspace(cli, tmpdir, datafiles): | 
| 72 | 72 |  # Test making a change using the workspace
 | 
| 73 | 73 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 74 | 74 |                      reason='Examples are writtent for x86_64')
 | 
| 75 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 75 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 76 | 76 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 77 | 77 |  def test_make_change_in_workspace(cli, tmpdir, datafiles):
 | 
| 78 | 78 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -3,7 +3,7 @@ import pytest | 
| 3 | 3 |  | 
| 4 | 4 |  from tests.testutils import cli_integration as cli
 | 
| 5 | 5 |  from tests.testutils.integration import assert_contains
 | 
| 6 | -from tests.testutils.site import IS_LINUX, MACHINE_ARCH
 | |
| 6 | +from tests.testutils.site import HAVE_OSTREE, IS_LINUX, MACHINE_ARCH
 | |
| 7 | 7 |  | 
| 8 | 8 |  | 
| 9 | 9 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -34,7 +34,7 @@ def workaround_setuptools_bug(project): | 
| 34 | 34 |  # amhello project for this.
 | 
| 35 | 35 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 36 | 36 |                      reason='Examples are writtent for x86_64')
 | 
| 37 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 37 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_OSTREE, reason='Only available on linux with ostree')
 | |
| 38 | 38 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 39 | 39 |  def test_autotools_build(cli, tmpdir, datafiles):
 | 
| 40 | 40 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -59,7 +59,7 @@ def test_autotools_build(cli, tmpdir, datafiles): | 
| 59 | 59 |  # Test running an executable built with autotools
 | 
| 60 | 60 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 61 | 61 |                      reason='Examples are writtent for x86_64')
 | 
| 62 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 62 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_OSTREE, reason='Only available on linux with ostree')
 | |
| 63 | 63 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 64 | 64 |  def test_autotools_run(cli, tmpdir, datafiles):
 | 
| 65 | 65 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -3,7 +3,7 @@ import pytest | 
| 3 | 3 |  | 
| 4 | 4 |  from tests.testutils import cli_integration as cli
 | 
| 5 | 5 |  from tests.testutils.integration import assert_contains
 | 
| 6 | -from tests.testutils.site import IS_LINUX, MACHINE_ARCH
 | |
| 6 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX, MACHINE_ARCH
 | |
| 7 | 7 |  | 
| 8 | 8 |  | 
| 9 | 9 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -14,7 +14,7 @@ DATA_DIR = os.path.join( | 
| 14 | 14 |  | 
| 15 | 15 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 16 | 16 |                      reason='Examples are writtent for x86_64')
 | 
| 17 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 17 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 18 | 18 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 19 | 19 |  def test_integration_commands_build(cli, tmpdir, datafiles):
 | 
| 20 | 20 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -27,7 +27,7 @@ def test_integration_commands_build(cli, tmpdir, datafiles): | 
| 27 | 27 |  # Test running the executable
 | 
| 28 | 28 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 29 | 29 |                      reason='Examples are writtent for x86_64')
 | 
| 30 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 30 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 31 | 31 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 32 | 32 |  def test_integration_commands_run(cli, tmpdir, datafiles):
 | 
| 33 | 33 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -3,7 +3,7 @@ import pytest | 
| 3 | 3 |  | 
| 4 | 4 |  from tests.testutils import cli_integration as cli
 | 
| 5 | 5 |  from tests.testutils.integration import assert_contains
 | 
| 6 | -from tests.testutils.site import IS_LINUX, MACHINE_ARCH
 | |
| 6 | +from tests.testutils.site import IS_LINUX, HAVE_BWRAP, MACHINE_ARCH
 | |
| 7 | 7 |  | 
| 8 | 8 |  pytestmark = pytest.mark.integration
 | 
| 9 | 9 |  | 
| ... | ... | @@ -15,7 +15,7 @@ DATA_DIR = os.path.join( | 
| 15 | 15 |  # Test that the project builds successfully
 | 
| 16 | 16 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 17 | 17 |                      reason='Examples are writtent for x86_64')
 | 
| 18 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 18 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 19 | 19 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 20 | 20 |  def test_build(cli, tmpdir, datafiles):
 | 
| 21 | 21 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -27,7 +27,7 @@ def test_build(cli, tmpdir, datafiles): | 
| 27 | 27 |  # Test the callHello script works as expected.
 | 
| 28 | 28 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 29 | 29 |                      reason='Examples are writtent for x86_64')
 | 
| 30 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 30 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 31 | 31 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 32 | 32 |  def test_shell_call_hello(cli, tmpdir, datafiles):
 | 
| 33 | 33 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -3,7 +3,7 @@ import pytest | 
| 3 | 3 |  | 
| 4 | 4 |  from tests.testutils import cli_integration as cli
 | 
| 5 | 5 |  from tests.testutils.integration import assert_contains
 | 
| 6 | -from tests.testutils.site import IS_LINUX, MACHINE_ARCH
 | |
| 6 | +from tests.testutils.site import IS_LINUX, HAVE_BWRAP, MACHINE_ARCH
 | |
| 7 | 7 |  | 
| 8 | 8 |  | 
| 9 | 9 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -14,7 +14,7 @@ DATA_DIR = os.path.join( | 
| 14 | 14 |  | 
| 15 | 15 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 16 | 16 |                      reason='Examples are writtent for x86_64')
 | 
| 17 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 17 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 18 | 18 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 19 | 19 |  def test_running_commands_build(cli, tmpdir, datafiles):
 | 
| 20 | 20 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -27,7 +27,7 @@ def test_running_commands_build(cli, tmpdir, datafiles): | 
| 27 | 27 |  # Test running the executable
 | 
| 28 | 28 |  @pytest.mark.skipif(MACHINE_ARCH != 'x86_64',
 | 
| 29 | 29 |                      reason='Examples are writtent for x86_64')
 | 
| 30 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 30 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 31 | 31 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 32 | 32 |  def test_running_commands_run(cli, tmpdir, datafiles):
 | 
| 33 | 33 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -3,6 +3,7 @@ import pytest | 
| 3 | 3 |  | 
| 4 | 4 |  from tests.testutils import cli_integration as cli
 | 
| 5 | 5 |  from tests.testutils.integration import assert_contains
 | 
| 6 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 6 | 7 |  | 
| 7 | 8 |  | 
| 8 | 9 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -18,6 +19,7 @@ DATA_DIR = os.path.join( | 
| 18 | 19 |  # amhello project for this.
 | 
| 19 | 20 |  @pytest.mark.integration
 | 
| 20 | 21 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 22 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 21 | 23 |  def test_autotools_build(cli, tmpdir, datafiles):
 | 
| 22 | 24 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 23 | 25 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -42,6 +44,7 @@ def test_autotools_build(cli, tmpdir, datafiles): | 
| 42 | 44 |  # amhello project for this.
 | 
| 43 | 45 |  @pytest.mark.integration
 | 
| 44 | 46 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 47 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 45 | 48 |  def test_autotools_confroot_build(cli, tmpdir, datafiles):
 | 
| 46 | 49 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 47 | 50 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -64,6 +67,7 @@ def test_autotools_confroot_build(cli, tmpdir, datafiles): | 
| 64 | 67 |  | 
| 65 | 68 |  # Test running an executable built with autotools
 | 
| 66 | 69 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 70 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 67 | 71 |  def test_autotools_run(cli, tmpdir, datafiles):
 | 
| 68 | 72 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 69 | 73 |      element_name = 'autotools/amhello.bst'
 | 
| ... | ... | @@ -3,6 +3,7 @@ import pytest | 
| 3 | 3 |  import shutil
 | 
| 4 | 4 |  | 
| 5 | 5 |  from tests.testutils import cli, cli_integration, create_artifact_share
 | 
| 6 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 6 | 7 |  from buildstream._exceptions import ErrorDomain
 | 
| 7 | 8 |  | 
| 8 | 9 |  | 
| ... | ... | @@ -16,6 +17,7 @@ DATA_DIR = os.path.join( | 
| 16 | 17 |  | 
| 17 | 18 |  | 
| 18 | 19 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 20 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 19 | 21 |  def test_buildtree_staged(cli_integration, tmpdir, datafiles):
 | 
| 20 | 22 |      # i.e. tests that cached build trees are staged by `bst shell --build`
 | 
| 21 | 23 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -31,6 +33,7 @@ def test_buildtree_staged(cli_integration, tmpdir, datafiles): | 
| 31 | 33 |  | 
| 32 | 34 |  | 
| 33 | 35 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 36 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 34 | 37 |  def test_buildtree_from_failure(cli_integration, tmpdir, datafiles):
 | 
| 35 | 38 |      # i.e. test that on a build failure, we can still shell into it
 | 
| 36 | 39 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -50,6 +53,7 @@ def test_buildtree_from_failure(cli_integration, tmpdir, datafiles): | 
| 50 | 53 |  # Check that build shells work when pulled from a remote cache
 | 
| 51 | 54 |  # This is to roughly simulate remote execution
 | 
| 52 | 55 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 56 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 53 | 57 |  def test_buildtree_pulled(cli, tmpdir, datafiles):
 | 
| 54 | 58 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 55 | 59 |      element_name = 'build-shell/buildtree.bst'
 | 
| ... | ... | @@ -5,7 +5,7 @@ from buildstream import _yaml | 
| 5 | 5 |  | 
| 6 | 6 |  from tests.testutils import cli_integration as cli
 | 
| 7 | 7 |  from tests.testutils.integration import assert_contains
 | 
| 8 | -from tests.testutils.site import IS_LINUX
 | |
| 8 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 9 | 9 |  | 
| 10 | 10 |  | 
| 11 | 11 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -16,7 +16,7 @@ DATA_DIR = os.path.join( | 
| 16 | 16 |  )
 | 
| 17 | 17 |  | 
| 18 | 18 |  | 
| 19 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 19 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubblewrap')
 | |
| 20 | 20 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 21 | 21 |  def test_build_uid_overridden(cli, tmpdir, datafiles):
 | 
| 22 | 22 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -35,7 +35,7 @@ def test_build_uid_overridden(cli, tmpdir, datafiles): | 
| 35 | 35 |      assert result.exit_code == 0
 | 
| 36 | 36 |  | 
| 37 | 37 |  | 
| 38 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 38 | +@pytest.mark.skipif(not IS_LINUX or not HAVE_BWRAP, reason='Only available on linux with bubbelwrap')
 | |
| 39 | 39 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 40 | 40 |  def test_build_uid_in_project(cli, tmpdir, datafiles):
 | 
| 41 | 41 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -55,6 +55,7 @@ def test_build_uid_in_project(cli, tmpdir, datafiles): | 
| 55 | 55 |  | 
| 56 | 56 |  | 
| 57 | 57 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 58 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 58 | 59 |  def test_build_uid_default(cli, tmpdir, datafiles):
 | 
| 59 | 60 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 60 | 61 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -7,7 +7,7 @@ from buildstream._exceptions import ErrorDomain | 
| 7 | 7 |  from conftest import clean_platform_cache
 | 
| 8 | 8 |  | 
| 9 | 9 |  from tests.testutils import cli_integration as cli, create_artifact_share
 | 
| 10 | -from tests.testutils.site import IS_LINUX
 | |
| 10 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 11 | 11 |  | 
| 12 | 12 |  | 
| 13 | 13 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -20,6 +20,7 @@ DATA_DIR = os.path.join( | 
| 20 | 20 |  | 
| 21 | 21 |  | 
| 22 | 22 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 23 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 23 | 24 |  def test_build_checkout_cached_fail(cli, tmpdir, datafiles):
 | 
| 24 | 25 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 25 | 26 |      element_path = os.path.join(project, 'elements', 'element.bst')
 | 
| ... | ... | @@ -63,6 +64,7 @@ def test_build_checkout_cached_fail(cli, tmpdir, datafiles): | 
| 63 | 64 |  | 
| 64 | 65 |  | 
| 65 | 66 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 67 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 66 | 68 |  def test_build_depend_on_cached_fail(cli, tmpdir, datafiles):
 | 
| 67 | 69 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 68 | 70 |      dep_path = os.path.join(project, 'elements', 'dep.bst')
 | 
| ... | ... | @@ -121,7 +123,7 @@ def test_build_depend_on_cached_fail(cli, tmpdir, datafiles): | 
| 121 | 123 |      assert cli.get_element_state(project, 'target.bst') == 'waiting'
 | 
| 122 | 124 |  | 
| 123 | 125 |  | 
| 124 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 126 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 125 | 127 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 126 | 128 |  @pytest.mark.parametrize("on_error", ("continue", "quit"))
 | 
| 127 | 129 |  def test_push_cached_fail(cli, tmpdir, datafiles, on_error):
 | 
| ... | ... | @@ -162,7 +164,7 @@ def test_push_cached_fail(cli, tmpdir, datafiles, on_error): | 
| 162 | 164 |          assert share.has_artifact('test', 'element.bst', cli.get_element_key(project, 'element.bst'))
 | 
| 163 | 165 |  | 
| 164 | 166 |  | 
| 165 | -@pytest.mark.skipif(not IS_LINUX, reason='Only available on linux')
 | |
| 167 | +@pytest.mark.skipif(not (IS_LINUX and HAVE_BWRAP), reason='Only available with bubblewrap on Linux')
 | |
| 166 | 168 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 167 | 169 |  def test_host_tools_errors_are_not_cached(cli, tmpdir, datafiles):
 | 
| 168 | 170 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -3,6 +3,7 @@ import pytest | 
| 3 | 3 |  | 
| 4 | 4 |  from tests.testutils import cli_integration as cli
 | 
| 5 | 5 |  from tests.testutils.integration import assert_contains
 | 
| 6 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 6 | 7 |  | 
| 7 | 8 |  | 
| 8 | 9 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -15,6 +16,7 @@ DATA_DIR = os.path.join( | 
| 15 | 16 |  | 
| 16 | 17 |  | 
| 17 | 18 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 19 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 18 | 20 |  def test_cmake_build(cli, tmpdir, datafiles):
 | 
| 19 | 21 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 20 | 22 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -33,6 +35,7 @@ def test_cmake_build(cli, tmpdir, datafiles): | 
| 33 | 35 |  | 
| 34 | 36 |  | 
| 35 | 37 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 38 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 36 | 39 |  def test_cmake_confroot_build(cli, tmpdir, datafiles):
 | 
| 37 | 40 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 38 | 41 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -51,6 +54,7 @@ def test_cmake_confroot_build(cli, tmpdir, datafiles): | 
| 51 | 54 |  | 
| 52 | 55 |  | 
| 53 | 56 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 57 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 54 | 58 |  def test_cmake_run(cli, tmpdir, datafiles):
 | 
| 55 | 59 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 56 | 60 |      element_name = 'cmake/cmakehello.bst'
 | 
| ... | ... | @@ -7,6 +7,7 @@ from buildstream import _yaml | 
| 7 | 7 |  | 
| 8 | 8 |  from tests.testutils import cli_integration as cli
 | 
| 9 | 9 |  from tests.testutils.integration import walk_dir
 | 
| 10 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 10 | 11 |  | 
| 11 | 12 |  | 
| 12 | 13 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -82,6 +83,7 @@ def create_compose_element(name, path, config={}): | 
| 82 | 83 |                      '/usr/share/doc', '/usr/share/doc/amhello',
 | 
| 83 | 84 |                      '/usr/share/doc/amhello/README'])
 | 
| 84 | 85 |  ])
 | 
| 86 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 85 | 87 |  def test_compose_include(cli, tmpdir, datafiles, include_domains,
 | 
| 86 | 88 |                           exclude_domains, expected):
 | 
| 87 | 89 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| ... | ... | @@ -3,6 +3,7 @@ import pytest | 
| 3 | 3 |  | 
| 4 | 4 |  from tests.testutils import cli_integration as cli
 | 
| 5 | 5 |  from tests.testutils.integration import assert_contains
 | 
| 6 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 6 | 7 |  | 
| 7 | 8 |  | 
| 8 | 9 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -18,6 +19,7 @@ DATA_DIR = os.path.join( | 
| 18 | 19 |  # makehello project for this.
 | 
| 19 | 20 |  @pytest.mark.integration
 | 
| 20 | 21 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 22 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 21 | 23 |  def test_make_build(cli, tmpdir, datafiles):
 | 
| 22 | 24 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 23 | 25 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -35,6 +37,7 @@ def test_make_build(cli, tmpdir, datafiles): | 
| 35 | 37 |  | 
| 36 | 38 |  # Test running an executable built with make
 | 
| 37 | 39 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 40 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 38 | 41 |  def test_make_run(cli, tmpdir, datafiles):
 | 
| 39 | 42 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 40 | 43 |      element_name = 'make/makehello.bst'
 | 
| ... | ... | @@ -4,6 +4,7 @@ import pytest | 
| 4 | 4 |  from buildstream import _yaml
 | 
| 5 | 5 |  | 
| 6 | 6 |  from tests.testutils import cli_integration as cli
 | 
| 7 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 7 | 8 |  | 
| 8 | 9 |  | 
| 9 | 10 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -31,6 +32,7 @@ def create_manual_element(name, path, config, variables, environment): | 
| 31 | 32 |  | 
| 32 | 33 |  | 
| 33 | 34 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 35 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 34 | 36 |  def test_manual_element(cli, tmpdir, datafiles):
 | 
| 35 | 37 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 36 | 38 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -64,6 +66,7 @@ strip | 
| 64 | 66 |  | 
| 65 | 67 |  | 
| 66 | 68 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 69 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 67 | 70 |  def test_manual_element_environment(cli, tmpdir, datafiles):
 | 
| 68 | 71 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 69 | 72 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -93,6 +96,7 @@ def test_manual_element_environment(cli, tmpdir, datafiles): | 
| 93 | 96 |  | 
| 94 | 97 |  | 
| 95 | 98 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 99 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 96 | 100 |  def test_manual_element_noparallel(cli, tmpdir, datafiles):
 | 
| 97 | 101 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 98 | 102 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -6,6 +6,7 @@ from buildstream import _yaml | 
| 6 | 6 |  | 
| 7 | 7 |  from tests.testutils import cli_integration as cli
 | 
| 8 | 8 |  from tests.testutils.integration import assert_contains
 | 
| 9 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 9 | 10 |  | 
| 10 | 11 |  | 
| 11 | 12 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -18,6 +19,7 @@ DATA_DIR = os.path.join( | 
| 18 | 19 |  | 
| 19 | 20 |  | 
| 20 | 21 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 22 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 21 | 23 |  def test_pip_build(cli, tmpdir, datafiles):
 | 
| 22 | 24 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 23 | 25 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -54,6 +56,7 @@ def test_pip_build(cli, tmpdir, datafiles): | 
| 54 | 56 |  | 
| 55 | 57 |  # Test running an executable built with pip
 | 
| 56 | 58 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 59 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 57 | 60 |  def test_pip_run(cli, tmpdir, datafiles):
 | 
| 58 | 61 |      # Create and build our test element
 | 
| 59 | 62 |      test_pip_build(cli, tmpdir, datafiles)
 | 
| ... | ... | @@ -6,6 +6,7 @@ from buildstream import _yaml | 
| 6 | 6 |  from tests.testutils import cli_integration as cli
 | 
| 7 | 7 |  from tests.testutils.python_repo import setup_pypi_repo
 | 
| 8 | 8 |  from tests.testutils.integration import assert_contains
 | 
| 9 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 9 | 10 |  | 
| 10 | 11 |  | 
| 11 | 12 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -72,6 +73,7 @@ def test_pip_source_import(cli, tmpdir, datafiles, setup_pypi_repo): | 
| 72 | 73 |  | 
| 73 | 74 |  | 
| 74 | 75 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 76 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 75 | 77 |  def test_pip_source_build(cli, tmpdir, datafiles, setup_pypi_repo):
 | 
| 76 | 78 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 77 | 79 |      element_path = os.path.join(project, 'elements')
 | 
| ... | ... | @@ -4,6 +4,7 @@ import pytest | 
| 4 | 4 |  | 
| 5 | 5 |  from tests.testutils import cli_integration as cli, create_artifact_share
 | 
| 6 | 6 |  from tests.testutils.integration import assert_contains
 | 
| 7 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 7 | 8 |  from buildstream._exceptions import ErrorDomain, LoadErrorReason
 | 
| 8 | 9 |  | 
| 9 | 10 |  | 
| ... | ... | @@ -30,6 +31,7 @@ def default_state(cli, tmpdir, share): | 
| 30 | 31 |  # directory of an element.
 | 
| 31 | 32 |  @pytest.mark.integration
 | 
| 32 | 33 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 34 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 33 | 35 |  def test_pullbuildtrees(cli, tmpdir, datafiles, integration_cache):
 | 
| 34 | 36 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 35 | 37 |      element_name = 'autotools/amhello.bst'
 | 
| ... | ... | @@ -4,6 +4,7 @@ import pytest | 
| 4 | 4 |  from buildstream import _yaml
 | 
| 5 | 5 |  | 
| 6 | 6 |  from tests.testutils import cli_integration as cli
 | 
| 7 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 7 | 8 |  | 
| 8 | 9 |  | 
| 9 | 10 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -30,6 +31,7 @@ def create_script_element(name, path, config={}, variables={}): | 
| 30 | 31 |  | 
| 31 | 32 |  | 
| 32 | 33 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 34 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 33 | 35 |  def test_script(cli, tmpdir, datafiles):
 | 
| 34 | 36 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 35 | 37 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -57,6 +59,7 @@ def test_script(cli, tmpdir, datafiles): | 
| 57 | 59 |  | 
| 58 | 60 |  | 
| 59 | 61 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 62 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 60 | 63 |  def test_script_root(cli, tmpdir, datafiles):
 | 
| 61 | 64 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 62 | 65 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -88,6 +91,7 @@ def test_script_root(cli, tmpdir, datafiles): | 
| 88 | 91 |  | 
| 89 | 92 |  | 
| 90 | 93 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 94 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 91 | 95 |  def test_script_no_root(cli, tmpdir, datafiles):
 | 
| 92 | 96 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 93 | 97 |      element_path = os.path.join(project, 'elements')
 | 
| ... | ... | @@ -110,6 +114,7 @@ def test_script_no_root(cli, tmpdir, datafiles): | 
| 110 | 114 |  | 
| 111 | 115 |  | 
| 112 | 116 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 117 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 113 | 118 |  def test_script_cwd(cli, tmpdir, datafiles):
 | 
| 114 | 119 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 115 | 120 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -140,6 +145,7 @@ def test_script_cwd(cli, tmpdir, datafiles): | 
| 140 | 145 |  | 
| 141 | 146 |  | 
| 142 | 147 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 148 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 143 | 149 |  def test_script_layout(cli, tmpdir, datafiles):
 | 
| 144 | 150 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 145 | 151 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -158,6 +164,7 @@ def test_script_layout(cli, tmpdir, datafiles): | 
| 158 | 164 |  | 
| 159 | 165 |  | 
| 160 | 166 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 167 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 161 | 168 |  def test_regression_cache_corruption(cli, tmpdir, datafiles):
 | 
| 162 | 169 |      project = str(datafiles)
 | 
| 163 | 170 |      checkout_original = os.path.join(cli.directory, 'checkout-original')
 | 
| ... | ... | @@ -187,6 +194,7 @@ def test_regression_cache_corruption(cli, tmpdir, datafiles): | 
| 187 | 194 |  | 
| 188 | 195 |  | 
| 189 | 196 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 197 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 190 | 198 |  def test_regression_tmpdir(cli, tmpdir, datafiles):
 | 
| 191 | 199 |      project = str(datafiles)
 | 
| 192 | 200 |      element_name = 'script/tmpdir.bst'
 | 
| ... | ... | @@ -196,6 +204,7 @@ def test_regression_tmpdir(cli, tmpdir, datafiles): | 
| 196 | 204 |  | 
| 197 | 205 |  | 
| 198 | 206 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 207 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 199 | 208 |  def test_regression_cache_corruption_2(cli, tmpdir, datafiles):
 | 
| 200 | 209 |      project = str(datafiles)
 | 
| 201 | 210 |      checkout_original = os.path.join(cli.directory, 'checkout-original')
 | 
| ... | ... | @@ -5,6 +5,7 @@ from buildstream import _yaml | 
| 5 | 5 |  from buildstream._exceptions import ErrorDomain
 | 
| 6 | 6 |  | 
| 7 | 7 |  from tests.testutils import cli_integration as cli
 | 
| 8 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 8 | 9 |  | 
| 9 | 10 |  | 
| 10 | 11 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -48,6 +49,7 @@ def execute_shell(cli, project, command, *, config=None, mount=None, element='ba | 
| 48 | 49 |  # Test running something through a shell, allowing it to find the
 | 
| 49 | 50 |  # executable
 | 
| 50 | 51 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 52 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 51 | 53 |  def test_shell(cli, tmpdir, datafiles):
 | 
| 52 | 54 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 53 | 55 |  | 
| ... | ... | @@ -58,6 +60,7 @@ def test_shell(cli, tmpdir, datafiles): | 
| 58 | 60 |  | 
| 59 | 61 |  # Test running an executable directly
 | 
| 60 | 62 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 63 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 61 | 64 |  def test_executable(cli, tmpdir, datafiles):
 | 
| 62 | 65 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 63 | 66 |  | 
| ... | ... | @@ -69,6 +72,7 @@ def test_executable(cli, tmpdir, datafiles): | 
| 69 | 72 |  # Test shell environment variable explicit assignments
 | 
| 70 | 73 |  @pytest.mark.parametrize("animal", [("Horse"), ("Pony")])
 | 
| 71 | 74 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 75 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 72 | 76 |  def test_env_assign(cli, tmpdir, datafiles, animal):
 | 
| 73 | 77 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 74 | 78 |      expected = animal + '\n'
 | 
| ... | ... | @@ -88,6 +92,7 @@ def test_env_assign(cli, tmpdir, datafiles, animal): | 
| 88 | 92 |  # Test shell environment variable explicit assignments with host env var expansion
 | 
| 89 | 93 |  @pytest.mark.parametrize("animal", [("Horse"), ("Pony")])
 | 
| 90 | 94 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 95 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 91 | 96 |  def test_env_assign_expand_host_environ(cli, tmpdir, datafiles, animal):
 | 
| 92 | 97 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 93 | 98 |      expected = 'The animal is: {}\n'.format(animal)
 | 
| ... | ... | @@ -110,6 +115,7 @@ def test_env_assign_expand_host_environ(cli, tmpdir, datafiles, animal): | 
| 110 | 115 |  # when running an isolated shell
 | 
| 111 | 116 |  @pytest.mark.parametrize("animal", [("Horse"), ("Pony")])
 | 
| 112 | 117 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 118 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 113 | 119 |  def test_env_assign_isolated(cli, tmpdir, datafiles, animal):
 | 
| 114 | 120 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 115 | 121 |      result = execute_shell(cli, project, ['/bin/sh', '-c', 'echo ${ANIMAL}'], isolate=True, config={
 | 
| ... | ... | @@ -127,6 +133,7 @@ def test_env_assign_isolated(cli, tmpdir, datafiles, animal): | 
| 127 | 133 |  # Test running an executable in a runtime with no shell (i.e., no
 | 
| 128 | 134 |  # /bin/sh)
 | 
| 129 | 135 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 136 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 130 | 137 |  def test_no_shell(cli, tmpdir, datafiles):
 | 
| 131 | 138 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 132 | 139 |      element_path = os.path.join(project, 'elements')
 | 
| ... | ... | @@ -159,6 +166,7 @@ def test_no_shell(cli, tmpdir, datafiles): | 
| 159 | 166 |  # Test that bind mounts defined in project.conf work
 | 
| 160 | 167 |  @pytest.mark.parametrize("path", [("/etc/pony.conf"), ("/usr/share/pony/pony.txt")])
 | 
| 161 | 168 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 169 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 162 | 170 |  def test_host_files(cli, tmpdir, datafiles, path):
 | 
| 163 | 171 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 164 | 172 |      ponyfile = os.path.join(project, 'files', 'shell-mount', 'pony.txt')
 | 
| ... | ... | @@ -179,6 +187,7 @@ def test_host_files(cli, tmpdir, datafiles, path): | 
| 179 | 187 |  # Test that bind mounts defined in project.conf work
 | 
| 180 | 188 |  @pytest.mark.parametrize("path", [("/etc"), ("/usr/share/pony")])
 | 
| 181 | 189 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 190 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 182 | 191 |  def test_host_files_expand_environ(cli, tmpdir, datafiles, path):
 | 
| 183 | 192 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 184 | 193 |      hostpath = os.path.join(project, 'files', 'shell-mount')
 | 
| ... | ... | @@ -224,6 +233,7 @@ def test_isolated_no_mount(cli, tmpdir, datafiles, path): | 
| 224 | 233 |  # declared as optional, and that there is no warning if it is optional
 | 
| 225 | 234 |  @pytest.mark.parametrize("optional", [("mandatory"), ("optional")])
 | 
| 226 | 235 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 236 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 227 | 237 |  def test_host_files_missing(cli, tmpdir, datafiles, optional):
 | 
| 228 | 238 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 229 | 239 |      ponyfile = os.path.join(project, 'files', 'shell-mount', 'horsy.txt')
 | 
| ... | ... | @@ -259,6 +269,7 @@ def test_host_files_missing(cli, tmpdir, datafiles, optional): | 
| 259 | 269 |  # Test that bind mounts defined in project.conf work
 | 
| 260 | 270 |  @pytest.mark.parametrize("path", [("/etc/pony.conf"), ("/usr/share/pony/pony.txt")])
 | 
| 261 | 271 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 272 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 262 | 273 |  def test_cli_mount(cli, tmpdir, datafiles, path):
 | 
| 263 | 274 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 264 | 275 |      ponyfile = os.path.join(project, 'files', 'shell-mount', 'pony.txt')
 | 
| ... | ... | @@ -271,6 +282,7 @@ def test_cli_mount(cli, tmpdir, datafiles, path): | 
| 271 | 282 |  # Test that we can see the workspace files in a shell
 | 
| 272 | 283 |  @pytest.mark.integration
 | 
| 273 | 284 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 285 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 274 | 286 |  def test_workspace_visible(cli, tmpdir, datafiles):
 | 
| 275 | 287 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 276 | 288 |      workspace = os.path.join(cli.directory, 'workspace')
 | 
| ... | ... | @@ -304,6 +316,7 @@ def test_workspace_visible(cli, tmpdir, datafiles): | 
| 304 | 316 |  | 
| 305 | 317 |  # Test that '--sysroot' works
 | 
| 306 | 318 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 319 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 307 | 320 |  def test_sysroot(cli, tmpdir, datafiles):
 | 
| 308 | 321 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 309 | 322 |      base_element = "base/base-alpine.bst"
 | 
| ... | ... | @@ -333,6 +346,7 @@ def test_sysroot(cli, tmpdir, datafiles): | 
| 333 | 346 |  | 
| 334 | 347 |  # Test system integration commands can access devices in /dev
 | 
| 335 | 348 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 349 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 336 | 350 |  def test_integration_devices(cli, tmpdir, datafiles):
 | 
| 337 | 351 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 338 | 352 |      element_name = 'integration.bst'
 | 
| ... | ... | @@ -5,6 +5,7 @@ from buildstream import _yaml | 
| 5 | 5 |  | 
| 6 | 6 |  from tests.testutils import cli_integration as cli
 | 
| 7 | 7 |  from tests.testutils.integration import assert_contains
 | 
| 8 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 8 | 9 |  | 
| 9 | 10 |  | 
| 10 | 11 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -16,6 +17,7 @@ DATA_DIR = os.path.join( | 
| 16 | 17 |  | 
| 17 | 18 |  | 
| 18 | 19 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 20 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 19 | 21 |  def test_builddir_socket_ignored(cli, tmpdir, datafiles):
 | 
| 20 | 22 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 21 | 23 |      element_name = 'sockets/make-builddir-socket.bst'
 | 
| ... | ... | @@ -25,6 +27,7 @@ def test_builddir_socket_ignored(cli, tmpdir, datafiles): | 
| 25 | 27 |  | 
| 26 | 28 |  | 
| 27 | 29 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 30 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 28 | 31 |  def test_install_root_socket_ignored(cli, tmpdir, datafiles):
 | 
| 29 | 32 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 30 | 33 |      element_name = 'sockets/make-install-root-socket.bst'
 | 
| ... | ... | @@ -4,6 +4,7 @@ import pytest | 
| 4 | 4 |  from buildstream import _yaml, utils
 | 
| 5 | 5 |  from tests.testutils import create_repo, ALL_REPO_KINDS
 | 
| 6 | 6 |  from tests.testutils import cli_integration as cli
 | 
| 7 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 7 | 8 |  | 
| 8 | 9 |  | 
| 9 | 10 |  DATA_DIR = os.path.join(
 | 
| ... | ... | @@ -29,6 +30,7 @@ def create_test_directory(*path, mode=0o644): | 
| 29 | 30 |  @pytest.mark.integration
 | 
| 30 | 31 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 31 | 32 |  @pytest.mark.parametrize("kind", [(kind) for kind in ALL_REPO_KINDS] + ['local'])
 | 
| 33 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 32 | 34 |  def test_deterministic_source_umask(cli, tmpdir, datafiles, kind, integration_cache):
 | 
| 33 | 35 |      project = str(datafiles)
 | 
| 34 | 36 |      element_name = 'list'
 | 
| ... | ... | @@ -101,6 +103,7 @@ def test_deterministic_source_umask(cli, tmpdir, datafiles, kind, integration_ca | 
| 101 | 103 |  | 
| 102 | 104 |  @pytest.mark.integration
 | 
| 103 | 105 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 106 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 104 | 107 |  def test_deterministic_source_local(cli, tmpdir, datafiles, integration_cache):
 | 
| 105 | 108 |      """Only user rights should be considered for local source.
 | 
| 106 | 109 |      """
 | 
| ... | ... | @@ -4,6 +4,7 @@ import pytest | 
| 4 | 4 |  from buildstream import _yaml
 | 
| 5 | 5 |  | 
| 6 | 6 |  from tests.testutils import cli_integration as cli
 | 
| 7 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 7 | 8 |  | 
| 8 | 9 |  | 
| 9 | 10 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -16,6 +17,7 @@ DATA_DIR = os.path.join( | 
| 16 | 17 |  | 
| 17 | 18 |  | 
| 18 | 19 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 20 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 19 | 21 |  def test_stack(cli, tmpdir, datafiles):
 | 
| 20 | 22 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 21 | 23 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -6,6 +6,7 @@ from buildstream import _yaml | 
| 6 | 6 |  | 
| 7 | 7 |  from tests.testutils import cli_integration as cli
 | 
| 8 | 8 |  from tests.testutils.integration import assert_contains
 | 
| 9 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 9 | 10 |  | 
| 10 | 11 |  | 
| 11 | 12 |  pytestmark = pytest.mark.integration
 | 
| ... | ... | @@ -18,6 +19,7 @@ DATA_DIR = os.path.join( | 
| 18 | 19 |  | 
| 19 | 20 |  | 
| 20 | 21 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 22 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 21 | 23 |  def test_absolute_symlinks_made_relative(cli, tmpdir, datafiles):
 | 
| 22 | 24 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 23 | 25 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -41,6 +43,7 @@ def test_absolute_symlinks_made_relative(cli, tmpdir, datafiles): | 
| 41 | 43 |  | 
| 42 | 44 |  | 
| 43 | 45 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 46 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 44 | 47 |  def test_allow_overlaps_inside_symlink_with_dangling_target(cli, tmpdir, datafiles):
 | 
| 45 | 48 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 46 | 49 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -57,6 +60,7 @@ def test_allow_overlaps_inside_symlink_with_dangling_target(cli, tmpdir, datafil | 
| 57 | 60 |  | 
| 58 | 61 |  | 
| 59 | 62 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 63 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 60 | 64 |  def test_detect_symlink_overlaps_pointing_outside_sandbox(cli, tmpdir, datafiles):
 | 
| 61 | 65 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 62 | 66 |      checkout = os.path.join(cli.directory, 'checkout')
 | 
| ... | ... | @@ -3,7 +3,7 @@ import pytest | 
| 3 | 3 |  | 
| 4 | 4 |  from buildstream import _yaml
 | 
| 5 | 5 |  from tests.testutils import cli_integration as cli
 | 
| 6 | -from tests.testutils.site import IS_LINUX
 | |
| 6 | +from tests.testutils.site import HAVE_BWRAP, IS_LINUX
 | |
| 7 | 7 |  from tests.testutils.integration import walk_dir
 | 
| 8 | 8 |  | 
| 9 | 9 |  | 
| ... | ... | @@ -18,6 +18,7 @@ DATA_DIR = os.path.join( | 
| 18 | 18 |  | 
| 19 | 19 |  @pytest.mark.integration
 | 
| 20 | 20 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 21 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 21 | 22 |  def test_workspace_mount(cli, tmpdir, datafiles):
 | 
| 22 | 23 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 23 | 24 |      workspace = os.path.join(cli.directory, 'workspace')
 | 
| ... | ... | @@ -34,6 +35,7 @@ def test_workspace_mount(cli, tmpdir, datafiles): | 
| 34 | 35 |  | 
| 35 | 36 |  @pytest.mark.integration
 | 
| 36 | 37 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 38 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 37 | 39 |  def test_workspace_commanddir(cli, tmpdir, datafiles):
 | 
| 38 | 40 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 39 | 41 |      workspace = os.path.join(cli.directory, 'workspace')
 | 
| ... | ... | @@ -51,6 +53,7 @@ def test_workspace_commanddir(cli, tmpdir, datafiles): | 
| 51 | 53 |  | 
| 52 | 54 |  @pytest.mark.integration
 | 
| 53 | 55 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 56 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 54 | 57 |  def test_workspace_updated_dependency(cli, tmpdir, datafiles):
 | 
| 55 | 58 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 56 | 59 |      workspace = os.path.join(cli.directory, 'workspace')
 | 
| ... | ... | @@ -105,6 +108,7 @@ def test_workspace_updated_dependency(cli, tmpdir, datafiles): | 
| 105 | 108 |  | 
| 106 | 109 |  @pytest.mark.integration
 | 
| 107 | 110 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 111 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 108 | 112 |  def test_workspace_update_dependency_failed(cli, tmpdir, datafiles):
 | 
| 109 | 113 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 110 | 114 |      workspace = os.path.join(cli.directory, 'workspace')
 | 
| ... | ... | @@ -180,6 +184,7 @@ def test_workspace_update_dependency_failed(cli, tmpdir, datafiles): | 
| 180 | 184 |  | 
| 181 | 185 |  @pytest.mark.integration
 | 
| 182 | 186 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 187 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 183 | 188 |  def test_updated_dependency_nested(cli, tmpdir, datafiles):
 | 
| 184 | 189 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 185 | 190 |      workspace = os.path.join(cli.directory, 'workspace')
 | 
| ... | ... | @@ -233,6 +238,7 @@ def test_updated_dependency_nested(cli, tmpdir, datafiles): | 
| 233 | 238 |  | 
| 234 | 239 |  @pytest.mark.integration
 | 
| 235 | 240 |  @pytest.mark.datafiles(DATA_DIR)
 | 
| 241 | +@pytest.mark.skipif(IS_LINUX and not HAVE_BWRAP, reason='Only available with bubblewrap on Linux')
 | |
| 236 | 242 |  def test_incremental_configure_commands_run_only_once(cli, tmpdir, datafiles):
 | 
| 237 | 243 |      project = os.path.join(datafiles.dirname, datafiles.basename)
 | 
| 238 | 244 |      workspace = os.path.join(cli.directory, 'workspace')
 | 
