Skip to content

Commit

Permalink
Use new accessors in afw to improve test coverage.
Browse files Browse the repository at this point in the history
This also provides the only test coverage for the accessors themselves,
which would ideally be tested in afw as well.  However, it's much
easier to test them here (afw's tests seem to currently lack any way
to mock up a TanWcs easily), and DM-9901 may result in moving this
entire test to afw anyway.
  • Loading branch information
TallJimbo committed Apr 20, 2017
1 parent da6baa5 commit 7aa0963
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions tests/testTransforms.py
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,12 @@ def testMakeWcs(self):
fwd, rev,
lsst.afw.coord.IcrsCoord(crval, lsst.afw.geom.degrees)
)

self.assertFloatsAlmostEqual(fwd.getPoly().getXCoeffs(), wcs.getSipA())
self.assertFloatsAlmostEqual(fwd.getPoly().getYCoeffs(), wcs.getSipB())
self.assertFloatsAlmostEqual(rev.getPoly().getXCoeffs(), wcs.getSipAp())
self.assertFloatsAlmostEqual(rev.getPoly().getYCoeffs(), wcs.getSipBp())

# We can only test agreement with TanWcs in one direction, because
# TanWcs doesn't provide an inverse to skyToIntermediateWorldCoord.

Expand Down

0 comments on commit 7aa0963

Please sign in to comment.