| Total Complexity | 1 |
| Total Lines | 21 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | """Set Config message tests.""" |
||
| 2 | from pyof.v0x04.common.action import ControllerMaxLen |
||
| 3 | from pyof.v0x04.controller2switch.common import ConfigFlag |
||
| 4 | from pyof.v0x04.controller2switch.set_config import SetConfig |
||
| 5 | from tests.test_struct import TestStruct |
||
| 6 | |||
| 7 | |||
| 8 | class TestSetConfig(TestStruct): |
||
| 9 | """Test the Set Config message.""" |
||
| 10 | |||
| 11 | @classmethod |
||
| 12 | def setUpClass(cls): |
||
| 13 | """Configure raw file and its object in parent class (TestDump).""" |
||
| 14 | buffer = ControllerMaxLen.OFPCML_NO_BUFFER |
||
| 15 | super().setUpClass() |
||
| 16 | super().set_raw_dump_file('v0x04', 'ofpt_set_config') |
||
| 17 | super().set_raw_dump_object(SetConfig, xid=1201346349, |
||
| 18 | flags=ConfigFlag.OFPC_FRAG_NORMAL, |
||
| 19 | miss_send_len=buffer) |
||
| 20 | super().set_minimum_size(12) |
||
| 21 |