Esempio n. 1
0
 def test_create_network_6(self):
     np = network_parser.NetworkParser(DUMMY_PATH)
     network = np.create_network
     self.assertTrue(network["3"].check_link("3", "2"))
Esempio n. 2
0
 def test_create_network_5(self):
     np = network_parser.NetworkParser(DUMMY_PATH)
     network = np.create_network
     self.assertFalse(network["1"].check_link("2", "3"))
Esempio n. 3
0
 def test_create_network_1(self):
     np = network_parser.NetworkParser(DUMMY_PATH)
     network = np.create_network
     self.assertAlmostEqual(3, len(network.keys()))
Esempio n. 4
0
 def test__NetworkParser_2(self):
     np = network_parser.NetworkParser(DUMMY_PATH)
     self.assertEqual({"1", "2", "3"}, np.switches)
Esempio n. 5
0
 def test__NetworkParser_1(self):
     np = network_parser.NetworkParser(DUMMY_PATH)
     self.assertEqual({("1", "2"), ("2", "3")}, np.links)
Esempio n. 6
0
 def __create_network_parser(self, network_file_path):
     return network_parser.NetworkParser(network_file_path)