Browse Source

[2353] Check BoB.components_to_restart as a list

Mukund Sivaraman 12 years ago
parent
commit
93d27cba1a
1 changed files with 4 additions and 4 deletions
  1. 4 4
      src/bin/bind10/tests/bind10_test.py.in

+ 4 - 4
src/bin/bind10/tests/bind10_test.py.in

@@ -1496,9 +1496,9 @@ class TestBossComponents(unittest.TestCase):
         bob.reap_children()
 
         if runnable and is_running and not failed:
-            self.assertTrue(bob.components_to_restart)
+            self.assertTrue(component in bob.components_to_restart)
         else:
-            self.assertFalse(bob.components_to_restart)
+            self.assertEqual([], bob.components_to_restart)
 
     def test_reap_children(self):
         '''Test that children are queued to be restarted when they ask for it.'''
@@ -1526,7 +1526,7 @@ class TestBossComponents(unittest.TestCase):
         bob.components_to_restart = []
         # this should do nothing as the pid is unknown
         bob.reap_children()
-        self.assertFalse(bob.components_to_restart)
+        self.assertEqual([], bob.components_to_restart)
 
         # case where bob._get_process_exit_status() raises OSError with
         # errno.ECHILD
@@ -1535,7 +1535,7 @@ class TestBossComponents(unittest.TestCase):
         bob.components_to_restart = []
         # this should catch and handle the OSError
         bob.reap_children()
-        self.assertFalse(bob.components_to_restart)
+        self.assertEqual([], bob.components_to_restart)
 
         # case where bob._get_process_exit_status() raises OSError with
         # errno other than ECHILD