-
Notifications
You must be signed in to change notification settings - Fork 5
63 lines (61 loc) · 1.76 KB
/
test.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
name: CI
on:
push:
branches:
- 'main'
- '*.*'
tags:
- 'v*'
pull_request:
workflow_dispatch:
jobs:
test:
uses: OpenAstronomy/github-actions-workflows/.github/workflows/tox.yml@v1
with:
# NOTE: These are purposefully set to meaningless directories where there is no SSW
# or IDL installation so that the relevant tests will be skipped.
posargs: '--ssw-home=/home/foo --idl-home=/home/bar --log-level=DEBUG'
toxdeps: tox-pypi-filter
envs: |
- macos: py311
- windows: py311
- linux: py39
- linux: py310
- linux: py311
codestyle:
uses: OpenAstronomy/github-actions-workflows/.github/workflows/tox.yml@v1
with:
toxdeps: tox-pypi-filter
envs: |
- linux: codestyle
python-version: '3.11'
docs:
needs: [test]
uses: OpenAstronomy/github-actions-workflows/.github/workflows/tox.yml@v1
with:
toxdeps: tox-pypi-filter
envs: |
- linux: build_docs
python-version: '3.11'
publish:
# Build wheels when pushing to any branch except main
# publish.yml will only publish if tagged ^v.*
if: |
(
github.event_name != 'pull_request' && (
github.ref_name != 'main' ||
github.event_name == 'workflow_dispatch'
)
) || (
github.event_name == 'pull_request' &&
contains(github.event.pull_request.labels.*.name, 'Run publish')
)
needs: [test]
uses: OpenAstronomy/github-actions-workflows/.github/workflows/publish_pure_python.yml@main
with:
test_extras: 'dev'
test_command: 'pytest -p no:warnings --pyargs hissw'
submodules: false
python-version: '3.11'
secrets:
pypi_token: ${{ secrets.PYPI_TOKEN }}