Skip to content

Commit

Permalink
Add more testing for ReprocessVisitImageTask.
Browse files Browse the repository at this point in the history
  • Loading branch information
TallJimbo committed Dec 2, 2024
1 parent fba0c52 commit 376f658
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/test_reprocess_visit_image.py
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,14 @@ def test_run(self):
# Faintest non-sky source should be marked as used.
flux_sorted = result.sources[result.sources.argsort("slot_CalibFlux_instFlux")]
self.assertTrue(flux_sorted[~flux_sorted["sky_source"]]["calib_psf_used"][0])
# Test that the schema init-output agrees with the catalog output.
self.assertEqual(task.sources_schema.schema, result.sources_footprints.schema)
# The flux/instFlux ratio should be the LocalPhotoCalib value.
for record in result.sources_footprints:
self.assertAlmostEqual(
record["base_PsfFlux_flux"]/record["base_PsfFlux_instFlux"],
record['base_LocalPhotoCalib']
)


class ReprocessVisitImageTaskRunQuantumTests(lsst.utils.tests.TestCase):
Expand Down

0 comments on commit 376f658

Please sign in to comment.