forked from pyxnat/pyxnat
-
Notifications
You must be signed in to change notification settings - Fork 0
68 lines (65 loc) · 1.97 KB
/
ci.yml
File metadata and controls
68 lines (65 loc) · 1.97 KB
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
name: CI
on:
push:
branches:
- 'master'
- 'bbrc'
pull_request:
branches:
- 'master'
- 'bbrc'
jobs:
build:
runs-on: '${{ matrix.os }}'
strategy:
matrix:
os: ['ubuntu-latest']
python-version: ['3.8', '3.9']
steps:
- name: 'Set up Python ${{ matrix.python-version }}'
uses: actions/setup-python@v3
with:
python-version: '${{ matrix.python-version }}'
- uses: actions/checkout@v3
- name: Checkout xnat-docker-compose
uses: actions/checkout@v3
with:
repository: jhuguetn/xnat-docker-compose
ref: 1.8.10.5
path: xnat-docker-compose
- run: docker compose version
- run: python --version
- run: python -m pip install --upgrade pip
- name: Install dependencies
run: pip install -r requirements-dev.txt
- name: Start xnat-docker-compose
run: docker compose --env-file default.env up -d
working-directory: xnat-docker-compose
- run: sleep 120
if: ${{ matrix.python-version == '3.8' }}
- name: Check xnat-docker-compose
run: docker compose logs --tail=20 xnat-web
working-directory: xnat-docker-compose
- name: create config json (Central/NITRC)
id: create-json-central
uses: jsdaniell/create-json@v1.2.2
with:
name: ".central.cfg"
json: ${{ secrets.CENTRAL_CFG }}
- name: create config json (devxnat)
id: create-json-devxnat
uses: jsdaniell/create-json@v1.2.2
with:
name: ".devxnat.cfg"
json: ${{ secrets.XNAT_CFG }}
- name: Run tests (pytest)
run: pytest
env:
PYTHONPATH: $PYTHONPATH:$(pwd)
- name: Coveralls
#uses: coverallsapp/github-action@master
#with:
# github-token: ${{ secrets.GITHUB_TOKEN }}
run: coveralls --service=github
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}