.gitlab-ci.yml 1.17 KB
Newer Older
1
# Cache packages in between builds
julian.gethmann's avatar
julian.gethmann committed
2 3 4 5
cache:
  paths:
    - vendor/python

6
# This is a basic example for a packages or script which doesn't use
julian.gethmann's avatar
julian.gethmann committed
7 8
# services such as redis or postgres
before_script:
9 10 11 12 13 14
  - python -v                                   # Print out Python version for debugging
  # Setup git
  - apt-get install git
  - git config --global user.email "you@example.com"
  - git config --global user.name "Your Name"
  # Install dependencies of your package and the testing environment
julian.gethmann's avatar
julian.gethmann committed
15
  - pip install -r requirements.txt
16
  - pip install -r test-requirements.txt
julian.gethmann's avatar
julian.gethmann committed
17

18
# Run in different environments
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
# Currently tests only work with Python 3.6. See issue #17
# py27:
#   image: "python:2.7"
#   script:
#   - python setup.py test
#
# py33:
#   image: "python:3.3"
#   script:
#   - python setup.py test
#
# py34:
#   image: "python:3.4"
#   script:
#   - python setup.py test
#
# py35:
#   image: "python:3.5"
#   script:
#   - python setup.py test
julian.gethmann's avatar
julian.gethmann committed
39

40
py36:
julian.gethmann's avatar
julian.gethmann committed
41 42
  image: "python:3.6"
  script:
43
  - TZ='Europe/Berlin' python setup.py test
julian.gethmann's avatar
julian.gethmann committed
44 45

docs:
46 47
  before_script:
  - pip install Sphinx
julian.gethmann's avatar
julian.gethmann committed
48
  script:
49
  - python setup.py docs
50
  - mv build/sphinx/html public
51 52 53 54
  artifacts:
    paths:
    - public
  only:
julian.gethmann's avatar
julian.gethmann committed
55
  # - tags