server/test/unittest_schemaserial.py
changeset 9968 50f046bf0e50
parent 9965 a8769b752299
child 9990 c84ad981fc4a
equal deleted inserted replaced
9967:e65873ad0371 9968:50f046bf0e50
   439         schema = self.repo.schema
   439         schema = self.repo.schema
   440         self.assertEqual([('Company', 'Person')], list(schema['has_employee'].rdefs))
   440         self.assertEqual([('Company', 'Person')], list(schema['has_employee'].rdefs))
   441         self.assertEqual('O works_for S',
   441         self.assertEqual('O works_for S',
   442                          schema['has_employee'].rule)
   442                          schema['has_employee'].rule)
   443         self.assertEqual([('Company', 'Int')], list(schema['total_salary'].rdefs))
   443         self.assertEqual([('Company', 'Int')], list(schema['total_salary'].rdefs))
       
   444         self.assertEqual('Any SUM(SA) GROUPBY X WHERE P works_for X, P salary SA',
       
   445                          schema['total_salary'].rdefs['Company', 'Int'].formula)
   444 
   446 
   445 if __name__ == '__main__':
   447 if __name__ == '__main__':
   446     unittest_main()
   448     unittest_main()