def setUp(self): self.buf = buffer.ReceiveBuffer() self.port_stats = ofstats.PortStats( port_no=0xabcd, rx_packets=0x1234, tx_packets=0x5678, rx_bytes=0x1324, tx_bytes=0x5768, rx_dropped=0x1a2b, tx_dropped=0x3c4d, rx_errors=0xab12, tx_errors=0xcd34, rx_frame_err=0x1432, rx_over_err=0x2543, rx_crc_err=0x3654, collisions=0x4765)
def setUp(self): self.buf = buffer.ReceiveBuffer() self.hello_failed_error = oferror.OpenflowError( oferror.OFPET_HELLO_FAILED, oferror.OFPHFC_INCOMPATIBLE, ('incompatible version', )) self.action_bad_len_error = oferror.OpenflowError( oferror.OFPET_BAD_ACTION, oferror.OFPBAC_BAD_LEN, ('blahblahblah', ))
def setUp(self): self.buf = buffer.ReceiveBuffer() self.wildcards = ofmatch.Wildcards( in_port=True, dl_src=True, dl_dst=True, dl_vlan=True, dl_vlan_pcp=True, dl_type=True, nw_tos=False, nw_proto=False, nw_src=0, nw_dst=0, tp_src=False, tp_dst=False) self.table_stats = ofstats.TableStats( 0xac, 'eth_wildcards', self.wildcards, 0x100000, 0x1234, 0x5678, 0x9abcd)
def setUp(self): self.buf = buffer.ReceiveBuffer() self.match = ofmatch.Match( in_port=0x13, dl_src='\x13\x24\x35\x46\x57\x68', dl_dst='\x12\x23\x34\x45\x56\x67', dl_vlan=0x11, dl_vlan_pcp=0x22, dl_type=0x3344, nw_tos=0x80, nw_proto=0xcc, nw_src=('\xaa\xbb\xcc\xdd', 32), nw_dst=('\x21\x32\x43\x54', 32), tp_src=0x38, tp_dst=0x49) self.flow_stats = ofstats.FlowStats( 0xac, self.match, 0x10203040, 0x11223344, 0x1002, 0x0136, 0x0247, 0xffeeddccbbaa9988, 0x42, 0x0153, ( ofaction.ActionOutput(port=0x1234, max_len=0x9abc), ofaction.ActionSetDlDst(dl_addr='\x12\x34\x56\x78\xab\xcd')))
def setUp(self): self.buf = buffer.ReceiveBuffer() self.mfr_desc = 'Dummy Manufacturer Inc.' self.hw_desc = 'DummySwitch' self.sw_desc = 'DummyOS' self.serial_num = '0000000042' self.dp_desc = 'unittest switch' self.desc_stats = ofstats.DescriptionStats( mfr_desc=self.mfr_desc, hw_desc=self.hw_desc, sw_desc=self.sw_desc, serial_num=self.serial_num, dp_desc=self.dp_desc)
def setUp(self): self.buf = buffer.ReceiveBuffer()
def __init__(self): self.open = True self.buffer = buffer.ReceiveBuffer()
def setUp(self): self.buf = buffer.ReceiveBuffer() self.queue_stats = ofstats.QueueStats( port_no=0xabcd, queue_id=0x10203040, tx_bytes=0x5768, tx_packets=0x5678, tx_errors=0xcd34)