-
-
Notifications
You must be signed in to change notification settings - Fork 213
executable file
·81 lines (67 loc) · 1.76 KB
/
ci.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
name: ci
on:
push:
branches:
- master
- ci
pull_request:
branches:
- master
jobs:
doctest-and-lint:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: 3.6.15
- name: Install pinned dependencies
run: |
python -m pip install --upgrade pip
pip install astropy==3.0.1 docutils==0.17.1 matplotlib==3.3.0 numpy==1.15.4 pandas==1.0.0 pyflakes scipy==1.2.2 sphinx==1.7.2 spktype21
- name: Install Skyfield
run: |
python setup.py sdist
pip install -e .
- name: Doctest
run: |
./test-docs.sh
- name: Lint
run: |
pyflakes $(find skyfield/ -name '*.py')
test:
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
python: [python2, python3]
steps:
- uses: actions/checkout@v2
- name: Install
run: |
sudo apt install -q -q python3-virtualenv virtualenv
virtualenv -p ${{matrix.python}} V
- name: Build scripts
run: |
cat <<'EOF' > GITHUB_INSTALL.sh
source ./V/bin/activate
echo PATH is $PATH
which python
python --version
python -m pip install --upgrade pip
python setup.py sdist
python -m pip install dist/*
python -m pip install mock pandas
python -m pip install https://github.com/brandon-rhodes/assay/archive/master.zip
EOF
cat <<'EOF' > GITHUB_TEST.sh
source ./V/bin/activate
cd ci && ../test-code.sh
EOF
- name: Install
run: |
bash -e -x GITHUB_INSTALL.sh
- name: Test
run: |
bash -e -x GITHUB_TEST.sh