blob: b7bf28a6efb61ff80538aae90725cbb17ecb2187 [file] [log] [blame]
macauley_cheng420ddce2015-10-26 13:42:23 +08001import logging
2import oftest.base_tests as base_tests
3from oftest import config
4from oftest.testutils import *
5from util import *
6
7
8class features(base_tests.SimpleDataPlane):
9 def runTest(self):
10 delete_all_flows(self.controller)
11 delete_all_groups(self.controller)
12
13 test_ports = sorted(config["port_map"].keys())
14
15 json_result = apply_dpctl_cmd(self, config, "features")
16 #pprint(json_result)
17 result=json_result["RECEIVED"][1]
18 self.assertTrue(result["tabs"]==64, "Table size is not correct")
19
20class get_config(base_tests.SimpleDataPlane):
21 def runTest(self):
22 delete_all_flows(self.controller)
23 delete_all_groups(self.controller)
24
25 test_ports = sorted(config["port_map"].keys())
26
27 json_result = apply_dpctl_cmd(self, config, "get-config")
28 #pprint(json_result)
29 result=json_result["RECEIVED"][1]
30 self.assertNotEqual(result["conf"], {}, "Config reply nothing")
31
32