Skip to content

Commit

Permalink
Merge pull request #1266 from WilliamJamieson/feature/open-astronomy-…
Browse files Browse the repository at this point in the history
…wheel
  • Loading branch information
WilliamJamieson authored Dec 9, 2022
2 parents e7e8b97 + 4f090b0 commit f9c14ab
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 79 deletions.
14 changes: 5 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,16 +76,12 @@ jobs:
package:
needs: [test, dev, compatibility]
uses: OpenAstronomy/github-actions-workflows/.github/workflows/tox.yml@v1
uses: OpenAstronomy/github-actions-workflows/.github/workflows/publish_pure_python.yml@v1
with:
submodules: false
toxdeps: "'tox<4'"
# Any env name which does not start with `pyXY` will use this Python version.
default_python: '3.9'
envs: |
- linux: twine
- linux: prerelease
- linux: packaged
upload_to_pypi: false
upload_to_anaconda: false
test_extras: tests
test_command: pytest --pyargs asdf

asdf-schemas:
name: ${{ matrix.package_name }} tests
Expand Down
72 changes: 2 additions & 70 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist= py38,style
envlist= py38,py39,py39
isolated_build = True

[testenv]
Expand All @@ -19,7 +19,7 @@ deps=
legacy: numpy~=1.18
legacy: pytest~=6.0.0
legacy: astropy~=5.0.4
numpydev,s390x: cython
numpydev: cython
extras= all,tests
# astropy will complain if the home directory is missing
passenv= HOME
Expand All @@ -28,58 +28,6 @@ commands=
pip freeze
pytest --remote-data

[testenv:s390x]
# As of 2020-01-23, The s390x container on Travis has a bug where
# /home/travis/.cache/pip/wheels is owned by root, which prevents
# us from installing packages unless we disable caching.
install_command= python -m pip install --no-cache-dir {opts} {packages}

[testenv:prerelease]
pip_pre= true

[testenv:packaged]
# The default tox working directory is in .tox in the source directory. If we
# execute pytest from there, it will discover tox.ini in the source directory
# and load the asdf module from the unpackaged sourcee, which is not what we
# want. The home directory does not have a tox.ini in any of its ancestors,
# so this will allow us to test the installed package.
usedevelop= false
changedir= {homedir}
commands=
pip freeze
pytest --pyargs asdf --remote-data

[testenv:egg_info]
deps=
commands=
python setup.py egg_info

[testenv:twine]
usedevelop= false
deps=
twine
commands=
twine check {distdir}/*

[testenv:docbuild]
extras= docs
commands=
pip freeze
sphinx-build -W docs build/docs

[testenv:checkdocs]
deps=
collective.checkdocs
pygments
commands=
python setup.py checkdocs

[testenv:style]
deps=
flake8
commands=
flake8 --count

# coverage run must be used because the pytest-asdf plugin will interfere
# with proper coverage measurement due to the order pytest loads its
# entry points.
Expand All @@ -99,19 +47,3 @@ extras= all,tests
commands=
pip freeze
pytest compatibility_tests/ --remote-data

[testenv:bandit]
deps=
bandit
toml
commands=
bandit -c bandit.yaml -r .

[testenv:codestyle]
skip_install = true
description = Run all style and file checks with pre-commit
deps =
pre-commit
commands =
pre-commit install-hooks
pre-commit run {posargs:--color always --all-files --show-diff-on-failure}

0 comments on commit f9c14ab

Please sign in to comment.