Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No longer test against casatools and casatasks #66

Merged
merged 4 commits into from
Feb 25, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,11 @@ jobs:
libraries: {}
coverage: 'false'

- linux: py36-test-casa
- linux: py37-test
- linux: py38-test
- linux: py39-test
- linux: py310-test-dev

- macos: py36-test-casa
- windows: py37-test
- macos: py38-test
- windows: py39-test-dev
Expand Down
12 changes: 5 additions & 7 deletions glue_astronomy/io/spectral_cube/tests/test_spectral_cube.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import numpy as np
import pytest
from astropy.utils.data import get_pkg_data_filename
from astropy.utils.data import get_pkg_data_filename, get_pkg_data_path
from glue.qglue import parse_data
from spectral_cube import SpectralCube

Expand All @@ -12,8 +11,7 @@ def test_identifier_fits():


def test_identifier_casa():
pytest.importorskip('casatools')
assert is_spectral_cube(get_pkg_data_filename('data/cube_3d.image'))
assert is_spectral_cube(get_pkg_data_path('data/cube_3d.image'))


def test_reader_fits():
Expand All @@ -38,9 +36,9 @@ def test_reader_fits_4d_fullstokes():


def test_reader_casa():
pytest.importorskip('casatools')
data = read_spectral_cube(get_pkg_data_filename('data/cube_3d.image'))
assert isinstance(data['STOKES I'], np.ndarray)
from dask import array as dask_array
data = read_spectral_cube(get_pkg_data_path('data/cube_3d.image'))
assert isinstance(data['STOKES I'], dask_array.Array)
assert data.shape == (2, 3, 4)


Expand Down
4 changes: 2 additions & 2 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ long_description_content_type = text/x-rst
[options]
zip_safe = False
packages = find:
python_requires = >=3.6
python_requires = >=3.7
setup_requires =
setuptools_scm
install_requires =
astropy>=4.0
glue-core>=1.0
regions>=0.4
specutils>=0.7
spectral-cube>=0.5.0
spectral-cube>=0.6.0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still don't like this. See #62


[options.extras_require]
docs =
Expand Down
6 changes: 1 addition & 5 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
[tox]
envlist = py{36,37,38,39,310}-{test,docs}-{casa,dev}
envlist = py{36,37,38,39,310}-{test,docs}-{,dev}
requires = pip >= 18.0
setuptools >= 30.3.0
indexserver =
NRAO = https://casa-pip.nrao.edu/repository/pypi-group/simple

[testenv]
passenv =
Expand All @@ -13,8 +11,6 @@ changedir =
deps =
dev: git+https://github.com/astropy/astropy
dev: git+https://github.com/astropy/specutils
casa: :NRAO:casatools
casa: :NRAO:casatasks
extras =
test: test
docs: docs
Expand Down