Skip to content
Snippets Groups Projects
.gitlab-ci.yml 2.37 KiB
Newer Older
## © University of Southampton IT Innovation Centre, 2018
##
## Copyright in this software belongs to University of Southampton
## IT Innovation Centre of Gamma House, Enterprise Road, 
## Chilworth Science Park, Southampton, SO16 7NS, UK.
##
## This software may not be used, sold, licensed, transferred, copied
## or reproduced in whole or in part in any manner or form or in or
## on any media by any person other than in accordance with the terms
## of the Licence Agreement supplied with the software, or otherwise
## without the prior written consent of the copyright owners.
##
## This software is distributed WITHOUT ANY WARRANTY, without even the
## implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
## PURPOSE, except where stated in the Licence Agreement supplied with
## the software.
##
##      Created By :            Michael Boniface
##      Created Date :          21-03-2018
##      Created for Project :   FLAME
MJB's avatar
MJB committed
stages:  
MJB's avatar
MJB committed
  - build
MJB's avatar
MJB committed

build:tests:
  stage: build
    - python setup.py sdist --dist-dir=../../build
    - python setup.py sdist --dist-dir=../../build  
MJB's avatar
MJB committed
  artifacts:
    paths:
MJB's avatar
MJB committed
    - build/clmctest-SNAPSHOT.tar.gz
    - build/clmcservice-SNAPSHOT.tar.gz
MJB's avatar
MJB committed
    expire_in: 1 day
MJB's avatar
MJB committed
  dependencies: 
    - build:tests
MJB's avatar
MJB committed
  script: 
#    - echo "REPO_USER=${REPO_USER}" > reporc
#    - echo "REPO_PASS=${REPO_PASS}" >> reporc
Michael Boniface's avatar
Michael Boniface committed
    - vagrant --fixture=scripts -- up
MJB's avatar
MJB committed
    - vagrant --fixture=scripts -- ssh test-runner -- -tt "pip3 install /vagrant/build/clmctest-SNAPSHOT.tar.gz"
MJB's avatar
MJB committed
    - vagrant --fixture=scripts -- ssh test-runner -- -tt "pytest -s --pyargs clmctest.scripts"
MJB's avatar
MJB committed
    - vagrant --fixture=monitoring -- up
MJB's avatar
MJB committed
    - vagrant --fixture=monitoring -- ssh test-runner -- -tt "pip3 install /vagrant/build/clmcservice-SNAPSHOT.tar.gz"    
MJB's avatar
MJB committed
    - vagrant --fixture=monitoring -- ssh test-runner -- -tt "pytest -s --pyargs clmctest.monitoring"  
    - vagrant --fixture=monitoring -- ssh test-runner -- -tt "pytest -s --pyargs clmcservice.tests"    
MJB's avatar
MJB committed
    - vagrant --fixture=inputs -- up
    - vagrant --fixture=inputs -- ssh test-runner -- -tt "pytest -s --pyargs clmctest.inputs"        
MJB's avatar
MJB committed
  when: on_success      
MJB's avatar
MJB committed
    - python scripts/test/deleteallvms.py