-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
174 additions
and
151 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
exclude_dirs: | ||
- tweakwcs/tests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
- '*.x' | ||
tags: | ||
- "*" | ||
pull_request: | ||
schedule: | ||
- cron: '0 6 * * 1' | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
check: | ||
uses: OpenAstronomy/github-actions-workflows/.github/workflows/tox.yml@v1 | ||
with: | ||
envs: | | ||
- linux: check-style | ||
- linux: check-security | ||
- linux: check-build | ||
test: | ||
uses: OpenAstronomy/github-actions-workflows/.github/workflows/tox.yml@v1 | ||
with: | ||
envs: | | ||
- linux: test-xdist | ||
python-version: 3.8 | ||
- macos: test-xdist | ||
python-version: 3.8 | ||
- windows: test-xdist | ||
python-version: 3.8 | ||
- linux: test-numpy121-xdist | ||
python-version: 3.9 | ||
- linux: test-numpy123-xdist | ||
python-version: 3.9 | ||
- linux: test-numpy125-xdist | ||
python-version: 3.9 | ||
- macos: test-numpy121-xdist | ||
python-version: 3.10 | ||
- linux: test-numpy125-xdist | ||
python-version: 3.10 | ||
- linux: test-xdist | ||
python-version: 3.11 | ||
pytest-results-summary: true | ||
- macos: test-xdist | ||
python-version: 3.11 | ||
pytest-results-summary: true | ||
- windows: test-xdist | ||
python-version: 3.11 | ||
pytest-results-summary: true | ||
- linux: test-pyargs-xdist | ||
python-version: 3.11 | ||
- linux: test-cov-xdist | ||
python-version: 3.12 | ||
coverage: codecov | ||
pytest-results-summary: true | ||
- macos: test-xdist | ||
python-version: 3.12 | ||
pytest-results-summary: true | ||
- windows: test-xdist | ||
python-version: 3.12 | ||
pytest-results-summary: true | ||
- linux: test-dev-xdist | ||
python-version: 3.12 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
[tox] | ||
envlist = | ||
check-{style,security,build} | ||
test{,-dev}{,-pyargs,-cov} | ||
test-numpy{120,122,125} | ||
build-{docs,dist} | ||
|
||
# tox environments are constructed with so-called 'factors' (or terms) | ||
# separated by hyphens, e.g. test-devdeps-cov. Lines below starting with factor: | ||
# will only take effect if that factor is included in the environment name. To | ||
# see a list of example environments that can be run, along with a description, | ||
# run: | ||
# | ||
# tox -l -v | ||
# | ||
|
||
[testenv:check-style] | ||
description = check code style, e.g. with flake8 | ||
skip_install = true | ||
deps = | ||
flake8 | ||
commands = | ||
flake8 . {posargs} | ||
|
||
[testenv:check-security] | ||
description = run bandit to check security compliance | ||
skip_install = true | ||
deps = | ||
bandit>=1.7 | ||
commands = | ||
bandit -r -ll -c .bandit.yaml tweakwcs | ||
|
||
[testenv:check-build] | ||
description = check build sdist/wheel and a strict twine check for metadata | ||
skip_install = true | ||
deps = | ||
twine>=3.3 | ||
build | ||
commands = | ||
python -m build . | ||
twine check --strict dist/* | ||
|
||
[testenv] | ||
description = | ||
run tests | ||
dev: with the latest developer version of key dependencies | ||
pyargs: with --pyargs on installed package | ||
warnings: treating warnings as errors | ||
cov: with coverage | ||
xdist: using parallel processing | ||
passenv = | ||
HOME | ||
GITHUB_* | ||
TOXENV | ||
CI | ||
CODECOV_* | ||
DISPLAY | ||
set_env = | ||
dev: PIP_EXTRA_INDEX_URL = https://pypi.anaconda.org/astropy/simple https://pypi.anaconda.org/liberfa/simple https://pypi.anaconda.org/scientific-python-nightly-wheels/simple | ||
|
||
args_are_paths = false | ||
change_dir = pyargs: {env:HOME} | ||
extras = | ||
test | ||
alldeps: all | ||
deps = | ||
xdist: pytest-xdist | ||
cov: pytest-cov | ||
numpy121: numpy==1.21.* | ||
numpy123: numpy==1.23.* | ||
numpy125: numpy==1.25.* | ||
commands_pre = | ||
dev: pip install -r requirements-dev.txt -U --upgrade-strategy eager | ||
pip freeze | ||
commands = | ||
pytest \ | ||
warnings: -W error \ | ||
xdist: -n auto \ | ||
pyargs: {toxinidir}/docs --pyargs tweakwcs \ | ||
cov: --cov=. --cov-config=pyproject.toml --cov-report=term-missing --cov-report=xml \ | ||
{posargs} | ||
|
||
[testenv:build-docs] | ||
description = invoke sphinx-build to build the HTML docs | ||
extras = docs | ||
commands = | ||
sphinx-build -W docs docs/_build | ||
|
||
[testenv:build-dist] | ||
description = build wheel and sdist | ||
skip_install = true | ||
deps = | ||
build | ||
commands = | ||
python -m build . |
This file was deleted.
Oops, something went wrong.