Exemplo n.º 1
0
 def setUp(self):
     self.repeater = Dhis2Repeater.wrap({
         "domain": "test-domain",
         "url": "https://dhis2.example.com/",
         "username": "******",
         "password": "******",
     })
Exemplo n.º 2
0
 def test_major_minor(self):
     repeater = Dhis2Repeater.wrap({
         "dhis2_version":
         "2.31",
         "dhis2_version_last_modified":
         self.just_now,
     })
     self.assertEqual(repeater.get_api_version(), 31)
Exemplo n.º 3
0
 def test_blank_raises_exception(self):
     repeater = Dhis2Repeater.wrap({
         "dhis2_version":
         "",
         "dhis2_version_last_modified":
         self.just_now,
     })
     with self.assertRaises(Dhis2Exception):
         repeater.get_api_version()