forked from pyomeca/bioptim
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.appveyor.yml
63 lines (51 loc) · 2.11 KB
/
.appveyor.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
#---------------------------------#
# environment configuration #
#---------------------------------#
# Build worker image (VM template)
image:
- macos
- Ubuntu2004
- Visual Studio 2019
# set clone depth
clone_depth: 5 # clone entire repository history if not defined
# There is no building process
build: off
# scripts that run after cloning repository
install:
- sh: if [[ $CI_LINUX == true ]]; then wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh; bash miniconda.sh -b -p $HOME/miniconda; export PATH="$HOME/miniconda/bin:$PATH"; else curl https://repo.continuum.io/miniconda/Miniconda3-latest-MacOSX-x86_64.sh -L -o miniconda.sh; bash miniconda.sh -b -p $HOME/miniconda; export PATH="$HOME/miniconda/bin:$PATH"; fi
- sh: hash -r
- sh: source activate
- cmd: SET MINICONDA_PATH="C:\\Miniconda38-x64"
- cmd: SET PATH=%MINICONDA_PATH%;%MINICONDA_PATH%"\\Scripts";%PATH%
- cmd: conda init cmd.exe
- conda config --set always_yes yes --set changeps1 no
- conda config --set auto_update_conda no
- conda update -q conda
# Set environment variables
- sh: BIOPTIM_FOLDER=`pwd`
- cmd: SET BIOPTIM_FOLDER=%cd%
# Setup the conda environment
- conda env update -n bioptim -f environment.yml
- conda activate bioptim
- conda install pytest-cov black pytest pytest-cov codecov -cconda-forge
- conda list
- sh: if [[ $CI_LINUX == true ]]; then black . -l120 --exclude "external/*" --check; fi
# Install ACADOS on LINUX and MAC
- cd external
- sh: if [[ $CI_LINUX == true ]]; then ./acados_install_linux.sh; else ./acados_install_mac.sh; fi
- cd ..
# to run your custom scripts instead of automatic tests
test_script:
- pytest -v --color=yes --cov-report term-missing --cov=bioptim tests
- python setup.py install
- sh: cd
- cmd: cd C:/
- python -c "import bioptim"
- sh: cd $BIOPTIM_FOLDER
- cmd: cd %BIOPTIM_FOLDER%
#---------------------------------#
# global handlers #
#---------------------------------#
# on successful build
on_success:
- sh: if [[ $CI_MACOS == true ]]; then codecov; fi