-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
99 lines (88 loc) · 2.91 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
language: python
script: pytest
os: linux
before_install:
# Additional info about the build
- uname -a
- df -h
- ulimit -a
# Install the Python environment
- source devtools/travis-ci/before_install.sh
- python -V
install:
# Create test environment for package
- python devtools/scripts/create_conda_env.py -n=test -p=$PYTHON_VER devtools/conda-envs/test_env.yaml
# Activate the test environment
- conda activate test
# Build and install package
#- python setup.py develop --no-deps
- pip install -e .
# Print details of the environment
- conda list
- pip freeze
notifications:
email: false
stages:
- lint
- test
- deploy
jobs:
fast_finish: true
include:
- stage: lint
name: "Check formatting of code for PEP-8"
os: linux
language: generic
env: PYTHON_VER=3.7
script:
- flake8 reference_handler
- yapf --diff --recursive reference_handler tests
- stage: test
name: "Tests on MacOS Python 3.6"
script:
- pytest -v reference_handler/tests/
os: osx
language: generic
env: PYTHON_VER=3.6
- stage: test
name: "Tests on MacOS Python 3.7"
script:
- pytest -v reference_handler/tests/
os: osx
language: generic
env: PYTHON_VER=3.7
- stage: test
name: "Tests on Linux Python 3.6"
script:
- pytest -v reference_handler/tests/
os: linux
language: generic # No need to set Python version since its conda
env: PYTHON_VER=3.6
- stage: test
name: "Tests and coverage on Linux Python 3.7"
script:
- pytest -v --cov=reference_handler reference_handler/tests/
after_success:
- codecov
os: linux
language: generic
env: PYTHON_VER=3.7
- stage: deploy
name: "Deploy to PyPi"
if: tag IS present
os: linux
dist: xenial
python: 3.7
script: skip
deploy:
provider: pypi
distributions: sdist bdist_wheel
skip_existing: true
on:
condition: $PYTHON_VER = 3.7
condition: $TRAVIS_OS_NAME = linux
repo: MolSSI/reference_handler
tags: true
username: seamm
password:
secure: KqSom7/u3yZJ6/QMYtpZOtVt3kLVEnnYRPly7TfmjOiwvV1d5rJF078lKYkyJJf2DNpgudazn3bETGppEHU0RcW7dCabtb6awoYFFfIorc35BVRSNnTKSTtboq8izoiylY2TU9O/dIj0f/jsmaNUsff23N1kgbW9Zq/nrCic/aYGocZqbymJBZ53JpH4NQyX2zclwyflcZh9hZ4lbhH8LJjEfZXSRd8FMTX5qZLDYfc080lUlotel/7w/NpMRJNQSzkwdDMcCPDimVJl68Ex+6mbkRSDfIleyTFhOOZCjS6HbON0gsmi/bEuQXdUtve0jTdyEnfTntHesT3ky7rIkDrTDjY8N9PiDyyRBP9ufLOPiUjvuWl2gVciEFAkz0Z/dlfcCMhgM4GpMZOb0RNf8YDgHvyz8rBR3E6rxOuTsr/drzUE7/8eaoqwrqlclwNNMn9mJ/AvDMs2s+CBlOxl7uX5p2Kaa2lJjGdEN0BzYj69Qxr95JpVqS4fm+KLS/t5W+UEUTgOKEBrS6ymHkX0HgPn74f94EDRKmb/9xqybPkQtrJo3hbp36MwlMbccKY/IEwXgjhzB5qsDZR4+p58jjHL9z8dWUulZodlWCMF3F7+ijZQu1hNUJAAN/JOzJXlUwxtgED+fURAA+gLRT2LjfRT89mKnkUHgnX6ViMl1iM=