forked from pyswmm/pyswmm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
circle.yml
42 lines (39 loc) · 1.86 KB
/
circle.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
# https://circleci.com/gh/OpenWaterAnalytics/pyswmm/
machine:
environment:
# Used by qthelpers to close widgets after a defined time
TEST_CI: "True"
# Python versions to tests (Maximum of 4 different versions)
PY_VERSIONS: "3.6 3.5 2.7"
# Environment variables used by astropy helpers
TRAVIS_OS_NAME: "linux"
# Conda variables and aliases for commands
CMD_CONDA: /home/ubuntu/miniconda/bin/conda
CMD_TEST_PYTEST: /home/ubuntu/miniconda/envs/test/bin/pytest
CMD_TEST_PYTHON: /home/ubuntu/miniconda/envs/test/bin/python
PATH: /home/ubuntu/miniconda/bin:$PATH
dependencies:
override:
# First convert PY_VERSIONS to an array and then select the python version based on the CIRCLE_NODE_INDEX
- export PY_VERSIONS=($PY_VERSIONS) &&
export TRAVIS_PYTHON_VERSION=${PY_VERSIONS[$CIRCLE_NODE_INDEX]} &&
echo -e "PYTHON = $TRAVIS_PYTHON_VERSION \n============" &&
git clone git://github.com/astropy/ci-helpers.git &&
source ci-helpers/travis/setup_conda_$TRAVIS_OS_NAME.sh;
# Install dependencies. This include test and lint dependencies
- $CMD_CONDA install -n test --file requirements-test.txt -c spyder-ide -q;
- if [[ "${TRAVIS_PYTHON_VERSION}" == "2.7" ]] ; then $CMD_CONDA install -n test enum34 -c -q; fi
# Install this package
- $CMD_TEST_PYTHON setup.py develop;
# Conda information
- $CMD_CONDA info --json;
test:
override:
# Check style
- export PATH="$HOME/miniconda/bin:$PATH" && source activate test && ciocheck setup.py -dt: # note the colon
parallel: true
- export PATH="$HOME/miniconda/bin:$PATH" && source activate test && ciocheck pyswmm -dt: # note the colon
parallel: true
# Run tests (enable when pytest is implemented)
#- $CMD_TEST_PYTEST pyswmm --cov=pyswmm: # note the colon
# parallel: true