Skip to content

Commit f5156ef

Browse files
authored
Merge pull request #218 from djarecka/ci/travis_osx
adding osx to the travis ci (closes #82)
2 parents c7518fb + fdb4613 commit f5156ef

File tree

2 files changed

+45
-0
lines changed

2 files changed

+45
-0
lines changed

.travis.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,12 @@ env:
3333
# Useful for testing un-released upstream fixes
3434
matrix:
3535
include:
36+
- os: osx
37+
osx_image: xcode11.2
38+
language: generic
39+
env:
40+
- JOBQUEUE="osx"
41+
- CONDA_VERSION="3.7"
3642
- python: 3.7
3743
env: JOBQUEUE="slurm"
3844
- language: go

ci/osx.sh

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# local build environment
2+
3+
function travis_before_install {
4+
wget https://raw.githubusercontent.com/mjirik/discon/master/tools/install_conda.sh && source install_conda.sh;
5+
conda config --add channels conda-forge;
6+
conda update -q conda;
7+
conda create --yes -n travis python=$CONDA_VERSION;
8+
source activate travis;
9+
travis_retry python -m pip install --upgrade $INSTALL_DEPENDS
10+
echo "my python pip"
11+
echo $(python --version)
12+
echo $(pip --version)
13+
}
14+
15+
function travis_install {
16+
if [ "$CHECK_TYPE" = "test" ]; then
17+
echo "Hello from pip"
18+
pip install $PIP_ARGS .
19+
# Verify import with bare install
20+
python -c 'import pydra; print(pydra.__version__)'
21+
fi
22+
}
23+
24+
function travis_before_script {
25+
if [ "$CHECK_TYPE" = "test" ]; then
26+
# Install test dependencies using similar methods...
27+
pip install ".[test]"
28+
fi
29+
}
30+
31+
function travis_script {
32+
if [ "$CHECK_TYPE" = "test" ]; then
33+
pytest -vs -n auto --cov pydra --cov-config .coveragerc --cov-report xml:cov.xml --doctest-modules pydra
34+
fi
35+
}
36+
37+
function travis_after_script {
38+
codecov --file cov.xml --flags unittests -e TRAVIS_JOB_NUMBER
39+
}

0 commit comments

Comments
 (0)