forked from mne-tools/mne-bids-pipeline
-
Notifications
You must be signed in to change notification settings - Fork 0
91 lines (87 loc) · 2.93 KB
/
run-tests.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
name: Run the test suite
on: [push, pull_request]
jobs:
# run-tests:
# name: ${{ matrix.os }}, Python ${{ matrix.python-version }}
# runs-on: ${{ matrix.os }}
# strategy:
# fail-fast: false
# matrix:
# # os: ["ubuntu-latest", "macos-latest", "windows-latest"]
# os: ["ubuntu-latest"]
# python-version: ["3.6", "3.7", "3.8"]
# defaults:
# run:
# shell: bash -l {0}
# steps:
# - uses: actions/checkout@v2
# - uses: conda-incubator/setup-miniconda@v2
# with:
# auto-update-conda: true
# python-version: ${{ matrix.python-version }}
# - name: Conda info
# run: conda info
# - name: Conda list
# run: conda list
# - name: Install datalad
# run: |
# conda install -y -c conda-forge git-annex datalad
# git config --global user.email "[email protected]"
# git config --global user.name "mne user"
# - name: Install Python dependencies
# run: |
# conda install -y -c conda-forge \
# python=${{ matrix.python-version }} \
# numpy scipy scikit-learn pandas json_tricks matplotlib \
# seaborn nibabel coloredlogs python-picard fire \
# typing_extensions # for Python <3.8
# # Install MNE
# pip install -U https://api.github.com/repos/mne-tools/mne-python/zipball/master
# # Install MNE-BIDS
# pip install -U https://api.github.com/repos/mne-tools/mne-bids/zipball/master
# - name: Check installation
# run: |
# which python
# git-annex version
# datalad --version
# mne_bids --version
# mne --version
# python -c "import mne; mne.sys_info()"
# - name: Setup reports artifact storage
# run: mkdir ~/reports
# - name: test ds000246
# run: |
# export DS=ds000246
# python ./tests/run_tests.py ${DS}
# mkdir ~/reports/${DS}
# cp ~/mne_data/${DS}/derivatives/mne-study-template/*/**/*.html ~/reports/${DS}/
# cp ~/mne_data/${DS}/derivatives/mne-study-template/*/**/*.tsv ~/reports/${DS}/
# rm -rf ~/mne_data/${DS}/derivatives/mne-study-template/
# - name: Store artifacts
# uses: actions/upload-artifact@v2
# with:
# name: reports
# path: ~/reports
check-style:
name: Check style
runs-on: "ubuntu-latest"
strategy:
fail-fast: false
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v2
- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
- name: Conda info
run: conda info
- name: Conda list
run: conda list
- name: Install flake8
run: conda install -y flake8
- name: Lint scripts with flake8
run: flake8 ./run*.py ./scripts --exclude ./scripts/freesurfer/contrib
- name: Lint config.py with flake8
run: flake8 ./config.py --ignore=E501,W503,W504