diff --git a/python/lsst/pipe/tasks/diffractionSpikeMask.py b/python/lsst/pipe/tasks/diffractionSpikeMask.py index 1f1990512..6803315b6 100644 --- a/python/lsst/pipe/tasks/diffractionSpikeMask.py +++ b/python/lsst/pipe/tasks/diffractionSpikeMask.py @@ -174,7 +174,7 @@ def run(self, exposure): Returns ------- - spikeCat : `lsst.afw.table.SourceCatalog` + spikeCat : `lsst.afw.table.SimpleCatalog` The entries from the reference catalog selected as stars with diffraction spikes. """ @@ -215,7 +215,7 @@ def run(self, exposure): mask) else: self.log.info("No bright stars found in the reference catalog; not masking diffraction spikes.") - return afwTable.SourceCatalog(refCat.schema) + return afwTable.SimpleCatalog(refCat.schema) return refCat[bright][spikeCandidates].copy(deep=True) @@ -355,7 +355,7 @@ def extractMagnitudes(self, refCat, filterLabel): Parameters ---------- - refCat : `lsst.afw.table.SourceCatalog` + refCat : `lsst.afw.table.SimpleCatalog` The input reference catalog. filterLabel : `str` Label of filter being calibrated. diff --git a/tests/test_diffractionSpikeMask.py b/tests/test_diffractionSpikeMask.py index 707be1801..0d2a99a6f 100644 --- a/tests/test_diffractionSpikeMask.py +++ b/tests/test_diffractionSpikeMask.py @@ -21,6 +21,7 @@ import os import glob +import unittest import numpy as np @@ -48,10 +49,6 @@ }) -def setup_module(module): - lsst.utils.tests.init() - - class DiffractionSpikeMaskTest(lsst.utils.tests.TestCase): def setUp(self): @@ -212,3 +209,16 @@ def test_maskSources(self): self.assertGreater(nClass2, 0) self.assertGreater(nClass3, 0) self.assertGreater(nClass4, 0) + + +class MemoryTestCase(lsst.utils.tests.MemoryTestCase): + pass + + +def setup_module(module): + lsst.utils.tests.init() + + +if __name__ == "__main__": + lsst.utils.tests.init() + unittest.main()