23 Test aggregator for obs_* packages. 25 The intention is for each obs package to have a single test class that inherits 26 from this collector class, thus "automatically" getting all new tests. If those 27 tests require setup that isn't defined in a given obs package, that obs package 28 will be broken until updated. This is intentional, as a way to prevent obs 29 packages from falling behind out of neglect. 32 from .
import butler_tests
33 from .
import mapper_tests
34 from .
import camera_tests
36 __all__ = [
"ObsTests"]
42 Aggregator class for all of the obs_* test classes. 44 Inherit from this class, then lsst.utils.tests.TestCase, in that order. 48 class TestObsExample(lsst.obs.base.tests.ObsTests, lsst.utils.tests.TestCase): 51 self.setUp_butler_get(...) 52 self.setUp_mapper(...) 53 self.setUp_camera(...) 58 Set up the necessary shared variables used by multiple tests. 62 butler: lsst.daf.persistence.Butler 63 A butler object, instantiated on the testdata repository for the 64 obs package being tested. 65 mapper: lsst.obs.CameraMapper 66 A CameraMapper object for your camera, instantiated on the testdata 67 repository the obs package being tested. 69 dictionary of (exposure name): (dataId of that exposure in the 70 testdata repository), with unittest.SkipTest as the value for any 71 exposures you do not have/do not want to test. It must contain a 72 valid 'raw' dataId, in addition to 'bias','flat','dark', which may 73 be set to SkipTest. For example:: 74 self.dataIds = {'raw': {'visit': 1, 'filter': 'g'}, 77 'dark': unittest.SkipTest
def setUp_tests(self, butler, mapper, dataIds)