Пример #1
0
 def test_summary_all_props_table(self):
     oh = tbls.create_observation_history(self.metadata)
     sh = tbls.create_slew_history(self.metadata)
     sfs = tbls.create_slew_final_state(self.metadata)
     ph = tbls.create_observation_proposal_history(self.metadata)
     p = tbls.create_proposal(self.metadata)
     f = tbls.create_field(self.metadata)
     summary = tbls.create_summary_all_props(self.metadata, oh, sh, sfs, p, ph, f)
     self.assertEqual(len(summary.c), 36)
Пример #2
0
    def test_write_field_table(self):
        field_topic = topic_helpers.field_tuple

        result = tbls.write_field(field_topic, 1000)
        fields = tbls.create_field(self.metadata)
        self.check_ordered_dict_to_table(result, fields)
        self.assertEqual(result['fieldId'], field_topic[0])
        self.assertEqual(result['ra'], field_topic[2])
        self.assertEqual(result['gb'], field_topic[5])
        self.assertEqual(result['el'], field_topic[6])
Пример #3
0
 def test_create_field_table(self):
     fields = tbls.create_field(self.metadata)
     self.assertEqual(len(fields.c), 9)
     self.assertEqual(len(fields.indexes), 4)