示例#1
0
 def test_order1(self):
     sc = ServiceDict(OT1.items())
     slist = sc.get_startup_list()
     printlist("startup list: ", slist)
     self.assertTrue(checkorder(slist, 'three', 'four', 'seven', 'six', 'two'))
     self.assertTrue(checkorder(slist, 'three', 'one', 'two'))
     self.assertTrue(checkorder(slist, 'eight', 'one', 'two'))
示例#2
0
 def test_order1(self):
     sc = ServiceDict(OT1.items())
     slist = sc.get_startup_list()
     printlist("startup list: ", slist)
     self.assertTrue(
         checkorder(slist, 'three', 'four', 'seven', 'six', 'two'))
     self.assertTrue(checkorder(slist, 'three', 'one', 'two'))
     self.assertTrue(checkorder(slist, 'eight', 'one', 'two'))
示例#3
0
 def test_order3(self):
     sc = ServiceDict(OT3.items())
     self.assertRaisesRegex(Exception, '^circular', lambda: sc.get_startup_list())
示例#4
0
 def test_order2(self):
     sc = ServiceDict(OT2.items())
     slist = sc.get_startup_list()
     printlist("startup list: ", slist)
     self.assertTrue(checkorder(slist, 'four', 'three', 'two'))
示例#5
0
 def test_order3(self):
     sc = ServiceDict(OT3.items())
     self.assertRaisesRegex(Exception, '^circular',
                            lambda: sc.get_startup_list())
示例#6
0
 def test_order2(self):
     sc = ServiceDict(OT2.items())
     slist = sc.get_startup_list()
     printlist("startup list: ", slist)
     self.assertTrue(checkorder(slist, 'four', 'three', 'two'))