From afa2244c63bee7ae39e744da9216d0de5c3623e1 Mon Sep 17 00:00:00 2001 From: Isaak Lim Date: Mon, 5 Feb 2018 17:08:02 +0100 Subject: [PATCH] seperate building and testing stages --- .gitlab-ci.yml | 34 ++++++++++++++++++++++++++++------ 1 file changed, 28 insertions(+), 6 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7911982..d696c6d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,25 +1,47 @@ -test-3.5: +stages: + - build + - test + +build-3.5: + stage: build tags: - Linux variables: GIT_SUBMODULE_STRATEGY: recursive script: - - virtualenv --clear -p python3.5 . - - source bin/activate + - virtualenv --clear -p python3.5 ./venv3 + - source venv3/bin/activate - python setup.py bdist_wheel --dist-dir dist3 + +build-2.7: + stage: build + tags: + - Linux + variables: + GIT_SUBMODULE_STRATEGY: recursive + script: + - virtualenv --clear -p python2.7 ./venv2 + - source venv2/bin/activate + - python setup.py bdist_wheel --dist-dir dist2 + +test-3.5: + stage: test + tags: + - Linux + script: + - source venv3/bin/activate - pip install dist3/*.whl - cd tests - python -m unittest discover test-2.7: + stage: test tags: - Linux variables: GIT_SUBMODULE_STRATEGY: recursive script: - - virtualenv --clear -p python2.7 . - - source bin/activate - - python setup.py bdist_wheel --dist-dir dist2 + - source venv2/bin/activate - pip install dist2/*.whl - cd tests - python -m unittest discover -- GitLab