summaryrefslogtreecommitdiff
path: root/.gitlab-ci.yml
diff options
context:
space:
mode:
authorTristan Maat <tristan.maat@codethink.co.uk>2017-09-14 11:37:59 +0100
committerTristan Maat <tristan.maat@codethink.co.uk>2017-09-28 14:46:35 +0100
commit4f814b1eed2aacf877c00e4d5aa41639c6f1afad (patch)
tree41c2390e769cc213a891a0dcd1406559c8b200db /.gitlab-ci.yml
parent206fc51a6cf57697f03e27508819eafaaee58317 (diff)
downloadbuildstream-4f814b1eed2aacf877c00e4d5aa41639c6f1afad.tar.gz
.gitlab-ci.yml: Add fallback tests to CI
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r--.gitlab-ci.yml61
1 files changed, 52 insertions, 9 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 0f1d3e691..c3526fa36 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -37,8 +37,44 @@ pytest:
# Run integration tests
#
-integration:
+integration_linux:
stage: test
+
+ script:
+ - dnf install -y findutils bzr which
+ - pip3 install coverage
+ - pip3 install .
+ - git clone https://gitlab.com/BuildStream/buildstream-tests.git
+ - cd buildstream-tests
+ - ./run-test.sh --arg --colors --cov ../.coveragerc test
+ - cd ..
+ - mkdir -p coverage-linux/
+ - cp buildstream-tests/.coverage coverage-linux/coverage.linux
+ - cp -a cache/buildstream/logs logs-linux
+
+ artifacts:
+ paths:
+ - coverage-linux/
+ - logs-linux/
+
+pytest_unix:
+ stage: test
+ variables:
+ BST_FORCE_BACKEND: "unix"
+ script:
+ - dnf erase -y bubblewrap ostree
+ - dnf install -y bzr patch
+ - python3 setup.py test
+ - mkdir -p coverage-pytest-unix
+ - cp .coverage.* coverage-pytest-unix/coverage.pytest-unix
+ artifacts:
+ paths:
+ - coverage-pytest-unix/
+
+integration_unix:
+ stage: test
+ variables:
+ BST_FORCE_BACKEND: "unix"
script:
- dnf install -y findutils bzr which
- pip3 install coverage
@@ -47,13 +83,14 @@ integration:
- cd buildstream-tests
- ./run-test.sh --arg --colors --cov ../.coveragerc test
- cd ..
- - mkdir -p coverage-integration/
- - cp buildstream-tests/.coverage coverage-integration/coverage.integration
- - cp -a cache/buildstream/logs logs-integration
+ - mkdir -p coverage-unix/
+ - cp buildstream-tests/.coverage coverage-unix/coverage.unix
+ - cp -a cache/buildstream/logs logs-unix
+
artifacts:
paths:
- - coverage-integration/
- - logs-integration/
+ - coverage-unix/
+ - logs-unix/
# Collate coverage reports
#
@@ -63,14 +100,20 @@ coverage:
- pip3 install coverage
- pip3 install .
- mkdir report
- - cp coverage-integration/coverage.integration report/.coverage
- - cp coverage-pytest/coverage.pytest report
- cd report
+ - cp ../coverage-linux/coverage.linux .coverage
+ - cp ../coverage-unix/coverage.unix .
+ - coverage combine --rcfile=../coveragerc -a ../coverage-unix/coverage.unix
+ - cp ../coverage-pytest/coverage.pytest .
- coverage combine --rcfile=../.coveragerc -a coverage.pytest
+ - cp ../coverage-pytest-unix/coverage.pytest-unix .
+ - coverage combine --rcfile=../.coveragerc -a coverage.pytest-unix
- coverage report --rcfile=../.coveragerc -m
dependencies:
- pytest
- - integration
+ - integration_linux
+ - pytest_unix
+ - integration_unix
# Automatically build documentation, only for merges which land
# on master branch.