before_script:
  - module add  python/3.6.1-2-anaconda
  - pip install --user pytest-pythonpath==0.7.1 pytest-cov==2.5.1
  - module load  nextflow/0.31.0
  - ln -s /project/shared/bicf_workflow_ref/workflow_testdata/atacseq/*fastq.gz test_data/

stages:
  - unit
  - integration

user_configuration:
  stage: unit
  script:
  - pytest -m unit
  - pytest -m unit --cov=./workflow/scripts

single_end_human:
  stage: integration
  only:
    - branches
    - master
  script:
  - nextflow run workflow/main.nf
  - pytest -m singleend_human
  artifacts:
    expire_in: 3 days

paired_end_mouse:
  stage: integration
  only:
    - branches
    - master
  script:
  - nextflow run workflow/main.nf --designFile "$CI_PROJECT_DIR/test_data/design_ENCSR451NAE_PE.txt" --genome 'GRCm38' --pairedEnd true
  - pytest -m pairedend_mouse
  artifacts:
    expire_in: 3 days
