def test_all_alive(self): results = probe(alive_servers) self.assertIn(True, [x.is_alive for x in results]) self.assertNotIn(False, [x.is_alive for x in results])
def test_mix(self): results = probe(mix) self.assertEqual(len(results), 199) self.assertIn(True, [x.is_alive for x in results]) self.assertIn(False, [x.is_alive for x in results])