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

change asdf.tests.helpers use to asdf.testing.helpers #168

Merged
merged 1 commit into from
Feb 24, 2023
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: 2 additions & 1 deletion asdf_astropy/converters/coordinates/tests/test_frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import asdf
import numpy as np
import pytest
from asdf.testing.helpers import yaml_to_asdf
from astropy import units as u
from astropy.coordinates import (
CIRS,
Expand Down Expand Up @@ -114,7 +115,7 @@ def test_legacy_icrs_deseialize():
unit: deg"""
truth = ICRS(ra=Longitude(25, unit=u.deg), dec=Latitude(45, unit=u.deg))

buff = asdf.tests.helpers.yaml_to_asdf(f"example: {example.strip()}")
buff = yaml_to_asdf(f"example: {example.strip()}")
with asdf.AsdfFile() as af:
af._open_impl(af, buff, mode="rw")
assert_frame_equal(af["example"], truth)
2 changes: 1 addition & 1 deletion asdf_astropy/converters/fits/tests/test_fits.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import asdf
import numpy as np
import pytest
from asdf.tests.helpers import yaml_to_asdf
from asdf.testing.helpers import yaml_to_asdf
from astropy.io import fits
from numpy.testing import assert_array_equal

Expand Down
2 changes: 1 addition & 1 deletion asdf_astropy/converters/table/tests/test_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import astropy.units as u
import numpy as np
import pytest
from asdf.tests.helpers import yaml_to_asdf
from asdf.testing.helpers import yaml_to_asdf
from astropy.coordinates import EarthLocation, SkyCoord
from astropy.table import Column, MaskedColumn, NdarrayMixin, QTable, Table
from astropy.time import Time, TimeDelta
Expand Down
3 changes: 2 additions & 1 deletion asdf_astropy/converters/time/tests/test_time.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import asdf
import numpy as np
import pytest
from asdf.testing.helpers import yaml_to_asdf
from astropy import units as u
from astropy.coordinates import EarthLocation
from astropy.time import Time
Expand Down Expand Up @@ -110,7 +111,7 @@ def create_examples():

@pytest.mark.parametrize("example", create_examples())
def test_read_examples(example):
buff = asdf.tests.helpers.yaml_to_asdf(f"example: {example['example'].strip()}")
buff = yaml_to_asdf(f"example: {example['example'].strip()}")
with asdf.AsdfFile() as af:
af._open_impl(af, buff, mode="rw")
assert np.all(af["example"] == example["truth"])
Expand Down
2 changes: 1 addition & 1 deletion asdf_astropy/converters/transform/tests/test_transform.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import astropy.modeling
import numpy as np
import pytest
from asdf.tests.helpers import yaml_to_asdf
from asdf.testing.helpers import yaml_to_asdf
from astropy import units as u
from astropy.modeling import models as astropy_models
from astropy.modeling.bounding_box import CompoundBoundingBox, ModelBoundingBox
Expand Down
2 changes: 1 addition & 1 deletion asdf_astropy/converters/unit/tests/test_quantity.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import asdf
import numpy as np
import pytest
from asdf.tests import helpers
from asdf.testing import helpers
from astropy import units
from astropy.units import Quantity
from numpy.testing import assert_array_equal
Expand Down
2 changes: 1 addition & 1 deletion asdf_astropy/converters/unit/tests/test_unit.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import asdf
import pytest
from asdf.tests import helpers
from asdf.testing import helpers
from astropy import units


Expand Down