loxi-prep: remove action_ prefix from callers
diff --git a/tests/FuncUtils.py b/tests/FuncUtils.py
index 7004580..31ccd19 100644
--- a/tests/FuncUtils.py
+++ b/tests/FuncUtils.py
@@ -26,7 +26,7 @@
msg.match = match
if priority != None :
msg.priority = priority
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = port
msg.actions.add(act)
self.controller.message_send(msg)
@@ -328,7 +328,7 @@
msg5.cookie = random.randint(0,9007199254740992)
msg5.command = ofp.OFPFC_MODIFY_STRICT
msg5.buffer_id = 0xffffffff
- act5 = ofp.action.action_output()
+ act5 = ofp.action.output()
act5.port = egress_port
msg5.actions.add(act5)
@@ -350,7 +350,7 @@
#out_port will be ignored for flow adds and flow modify (here for test-case Add_Modify_With_Outport)
msg8.out_port = of_ports[3]
msg8.buffer_id = 0xffffffff
- act8 = ofp.action.action_output()
+ act8 = ofp.action.output()
act8.port = of_ports[2]
msg8.actions.add(act8)
@@ -374,7 +374,7 @@
request = ofp.message.flow_mod()
request.match = match
request.buffer_id = 0xffffffff
- act = ofp.action.action_enqueue()
+ act = ofp.action.enqueue()
act.port = egress_port
act.queue_id = egress_queue_id
request.actions.add(act)
diff --git a/tests/actions.py b/tests/actions.py
index 522918a..ac4bc17 100644
--- a/tests/actions.py
+++ b/tests/actions.py
@@ -142,7 +142,7 @@
#Create a packet
pkt = simple_tcp_packet()
match = parse.packet_to_flow_match(pkt)
- act = ofp.action.action_output()
+ act = ofp.action.output()
#Delete all flows
delete_all_flows(self.controller)
@@ -193,7 +193,7 @@
#Create packet
pkt = simple_tcp_packet()
match = parse.packet_to_flow_match(pkt)
- act = ofp.action.action_output()
+ act = ofp.action.output()
for ingress_port in of_ports:
#Delete all flows
@@ -245,7 +245,7 @@
#Clear switch state
pkt = simple_tcp_packet()
match = parse.packet_to_flow_match(pkt)
- act = ofp.action.action_output()
+ act = ofp.action.output()
for ingress_port in of_ports:
#Delete the flows
@@ -293,7 +293,7 @@
#Create a packet
pkt = simple_tcp_packet()
match = parse.packet_to_flow_match(pkt)
- act = ofp.action.action_output()
+ act = ofp.action.output()
#Delete all flows
delete_all_flows(self.controller)
@@ -343,7 +343,7 @@
#Create a packet
pkt = simple_tcp_packet()
match = parse.packet_to_flow_match(pkt)
- act = ofp.action.action_output()
+ act = ofp.action.output()
#Delete the flows
delete_all_flows(self.controller)
@@ -397,7 +397,7 @@
pkt_out =ofp.message.packet_out();
pkt_out.data = str(pkt)
pkt_out.in_port = of_ports[0]
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = ofp.OFPP_TABLE
pkt_out.actions.add(act)
self.controller.message_send(pkt_out)
@@ -440,7 +440,7 @@
pkt = simple_tcp_packet(pktlen=len_wo_vid)
exp_pkt = simple_tcp_packet(pktlen=len_w_vid, dl_vlan_enable=True,
dl_vlan=new_vid,dl_vlan_pcp=0)
- vid_act = ofp.action.action_set_vlan_vid()
+ vid_act = ofp.action.set_vlan_vid()
vid_act.vlan_vid = new_vid
#Insert flow with action -- set vid , Send packet matching the flow, Verify recieved packet is expected packet
@@ -477,7 +477,7 @@
new_vid = 3
pkt = simple_tcp_packet(dl_vlan_enable=True, dl_vlan=old_vid)
exp_pkt = simple_tcp_packet(dl_vlan_enable=True, dl_vlan=new_vid)
- vid_act = ofp.action.action_set_vlan_vid()
+ vid_act = ofp.action.set_vlan_vid()
vid_act.vlan_vid = new_vid
#Insert flow with action -- set vid , Send packet matching the flow.Verify recieved packet is expected packet.
@@ -515,7 +515,7 @@
pktlen = 64 if config["minsize"] < 64 else config["minsize"]
pkt = simple_tcp_packet(pktlen=pktlen)
exp_pkt = simple_tcp_packet(dl_vlan_enable=True, dl_vlan=vlan_id,dl_vlan_pcp=vlan_pcp, pktlen=pktlen + 4)
- act = ofp.action.action_set_vlan_pcp()
+ act = ofp.action.set_vlan_pcp()
act.vlan_pcp = vlan_pcp
#Insert flow with action -- set vLAN priority, Send packet matching the flow, Verify recieved packet is expected packet
@@ -554,7 +554,7 @@
new_vlan_pcp = 3
pkt = simple_tcp_packet(dl_vlan_enable=True, dl_vlan=vid, dl_vlan_pcp=old_vlan_pcp)
exp_pkt = simple_tcp_packet(dl_vlan_enable=True, dl_vlan=vid, dl_vlan_pcp=new_vlan_pcp)
- vid_act = ofp.action.action_set_vlan_pcp()
+ vid_act = ofp.action.set_vlan_pcp()
vid_act.vlan_pcp = new_vlan_pcp
#Insert flow with action -- set vLAN priority, Send tagged packet matching the flow, Verify recieved packet is expected packet
diff --git a/tests/bsn_mirror.py b/tests/bsn_mirror.py
index 8eb4016..3c79ffd 100644
--- a/tests/bsn_mirror.py
+++ b/tests/bsn_mirror.py
@@ -11,7 +11,7 @@
from oftest.testutils import *
-class bsn_action_mirror(ofp.action.action_vendor):
+class bsn_action_mirror(ofp.action.vendor):
def __init__(self):
self.type = ofp.OFPAT_VENDOR
self.len = 24
@@ -139,7 +139,7 @@
act2 = bsn_action_mirror()
act2.dest_port = mirror_ports[1]
act2.copy_stage = 0
- act3 = ofp.action.action_output()
+ act3 = ofp.action.output()
act3.port = ports[1]
flow_mod = ofp.message.flow_mod()
flow_mod.match = match
diff --git a/tests/detailed_contr_sw_messages.py b/tests/detailed_contr_sw_messages.py
index 7f2787e..9fc8359 100644
--- a/tests/detailed_contr_sw_messages.py
+++ b/tests/detailed_contr_sw_messages.py
@@ -59,7 +59,7 @@
msg3.cookie = random.randint(0,9007199254740992)
msg3.buffer_id = 0xffffffff
- act3 = ofp.action.action_output()
+ act3 = ofp.action.output()
act3.port = of_ports[1]
msg3.actions.add(act3)
self.controller.message_send(msg3)
@@ -180,7 +180,7 @@
request.hard_timeout =9
request.idle_timeout =9
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = of_ports[1]
request.actions.add(act)
@@ -226,7 +226,7 @@
request.match.in_port = of_ports[0]
request.cookie = random.randint(0,9007199254740992)
request.buffer_id = 0xffffffff
- act3 = ofp.action.action_output()
+ act3 = ofp.action.output()
act3.port = of_ports[1]
request.actions.add(act3)
@@ -436,7 +436,7 @@
request.match = match
request.command = ofp.OFPFC_ADD
request.flags = request.flags|ofp.OFPFF_EMERG|ofp.OFPFF_SEND_FLOW_REM
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = of_ports[1]
request.actions.add(act)
@@ -753,7 +753,7 @@
msg3.hard_timeout = 1
msg3.buffer_id = 0xffffffff
msg3.match = match3
- act3 = ofp.action.action_output()
+ act3 = ofp.action.output()
act3.port = of_ports[1]
msg3.actions.add(act3)
diff --git a/tests/flow_expire.py b/tests/flow_expire.py
index f5b0773..ab19ec1 100644
--- a/tests/flow_expire.py
+++ b/tests/flow_expire.py
@@ -42,7 +42,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
of_ports = config["port_map"].keys()
of_ports.sort()
diff --git a/tests/flow_query.py b/tests/flow_query.py
index 0bbf3ee..d9dbe3c 100644
--- a/tests/flow_query.py
+++ b/tests/flow_query.py
@@ -526,38 +526,38 @@
pass # OUTPUT actions must come last
elif a == ofp.OFPAT_SET_VLAN_VID:
if not strip_vlanf:
- act = ofp.action.action_set_vlan_vid()
+ act = ofp.action.set_vlan_vid()
act.vlan_vid = fi.rand_vlan()
set_vlanf = True
elif a == ofp.OFPAT_SET_VLAN_PCP:
if not strip_vlanf:
- act = ofp.action.action_set_vlan_pcp()
+ act = ofp.action.set_vlan_pcp()
act.vlan_pcp = random.randint(0, (1 << 3) - 1)
set_vlanf = True
elif a == ofp.OFPAT_STRIP_VLAN:
if not set_vlanf:
- act = ofp.action.action_strip_vlan()
+ act = ofp.action.strip_vlan()
strip_vlanf = True
elif a == ofp.OFPAT_SET_DL_SRC:
- act = ofp.action.action_set_dl_src()
+ act = ofp.action.set_dl_src()
act.dl_addr = fi.rand_dl_addr()
elif a == ofp.OFPAT_SET_DL_DST:
- act = ofp.action.action_set_dl_dst()
+ act = ofp.action.set_dl_dst()
act.dl_addr = fi.rand_dl_addr()
elif a == ofp.OFPAT_SET_NW_SRC:
- act = ofp.action.action_set_nw_src()
+ act = ofp.action.set_nw_src()
act.nw_addr = fi.rand_ip_addr()
elif a == ofp.OFPAT_SET_NW_DST:
- act = ofp.action.action_set_nw_dst()
+ act = ofp.action.set_nw_dst()
act.nw_addr = fi.rand_ip_addr()
elif a == ofp.OFPAT_SET_NW_TOS:
- act = ofp.action.action_set_nw_tos()
+ act = ofp.action.set_nw_tos()
act.nw_tos = fi.rand_ip_tos()
elif a == ofp.OFPAT_SET_TP_SRC:
- act = ofp.action.action_set_tp_src()
+ act = ofp.action.set_tp_src()
act.tp_port = fi.rand_l4_port()
elif a == ofp.OFPAT_SET_TP_DST:
- act = ofp.action.action_set_tp_dst()
+ act = ofp.action.set_tp_dst()
act.tp_port = fi.rand_l4_port()
elif a == ofp.OFPAT_ENQUEUE:
pass # Enqueue actions must come last
@@ -571,7 +571,7 @@
# In not forecd, one third of the time, include ENQUEUE actions
# at end of list
# At most 1 ENQUEUE action
- act = ofp.action.action_enqueue()
+ act = ofp.action.enqueue()
(act.port, act.queue_id) = rand_pick(valid_queues)
self.actions.add(act)
if (((1 << ofp.OFPAT_OUTPUT) & actions_force) != 0 \
@@ -586,7 +586,7 @@
else random.randint(1, len(valid_ports))
port_idxs = port_idxs[0 : n]
for pi in port_idxs:
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = valid_ports[pi]
if act.port != ofp.OFPP_IN_PORT \
or wildcard_get(self.match.wildcards, ofp.OFPFW_IN_PORT) == 0:
@@ -636,45 +636,45 @@
port_idxs = shuffle(range(len(valid_ports)))
port_idxs = port_idxs[0 : random.randint(1, len(valid_ports))]
for pi in port_idxs:
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = valid_ports[pi]
self.actions.add(act)
elif a == ofp.OFPAT_SET_VLAN_VID:
- act = ofp.action.action_set_vlan_vid()
+ act = ofp.action.set_vlan_vid()
act.vlan_vid = fi.rand_vlan()
self.actions.add(act)
elif a == ofp.OFPAT_SET_VLAN_PCP:
- act = ofp.action.action_set_vlan_pcp()
+ act = ofp.action.set_vlan_pcp()
act.vlan_pcp = random.randint(0, (1 << 3) - 1)
elif a == ofp.OFPAT_STRIP_VLAN:
- act = ofp.action.action_strip_vlan()
+ act = ofp.action.strip_vlan()
self.actions.add(act)
elif a == ofp.OFPAT_SET_DL_SRC:
- act = ofp.action.action_set_dl_src()
+ act = ofp.action.set_dl_src()
act.dl_addr = fi.rand_dl_addr()
self.actions.add(act)
elif a == ofp.OFPAT_SET_DL_DST:
- act = ofp.action.action_set_dl_dst()
+ act = ofp.action.set_dl_dst()
act.dl_addr = fi.rand_dl_addr()
self.actions.add(act)
elif a == ofp.OFPAT_SET_NW_SRC:
- act = ofp.action.action_set_nw_src()
+ act = ofp.action.set_nw_src()
act.nw_addr = fi.rand_ip_addr()
self.actions.add(act)
elif a == ofp.OFPAT_SET_NW_DST:
- act = ofp.action.action_set_nw_dst()
+ act = ofp.action.set_nw_dst()
act.nw_addr = fi.rand_ip_addr()
self.actions.add(act)
elif a == ofp.OFPAT_SET_NW_TOS:
- act = ofp.action.action_set_nw_tos()
+ act = ofp.action.set_nw_tos()
act.nw_tos = fi.rand_ip_tos()
self.actions.add(act)
elif a == ofp.OFPAT_SET_TP_SRC:
- act = ofp.action.action_set_tp_src()
+ act = ofp.action.set_tp_src()
act.tp_port = fi.rand_l4_port()
self.actions.add(act)
elif a == ofp.OFPAT_SET_TP_DST:
- act = ofp.action.action_set_tp_dst()
+ act = ofp.action.set_tp_dst()
act.tp_port = fi.rand_l4_port()
self.actions.add(act)
elif a == ofp.OFPAT_ENQUEUE:
@@ -684,7 +684,7 @@
qidxs = shuffle(range(len(valid_queues)))
qidxs = qidxs[0 : random.randint(1, len(valid_queues))]
for qi in qidxs:
- act = ofp.action.action_enqueue()
+ act = ofp.action.enqueue()
(act.port, act.queue_id) = valid_queues[qi]
self.actions.add(act)
diff --git a/tests/flow_stats.py b/tests/flow_stats.py
index abd405c..eec92a6 100644
--- a/tests/flow_stats.py
+++ b/tests/flow_stats.py
@@ -125,7 +125,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
# build flow
ingress_port = of_ports[0];
@@ -191,7 +191,7 @@
flow_mod_msg.buffer_id = 0xffffffff
flow_mod_msg.idle_timeout = 0
flow_mod_msg.hard_timeout = 0
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = egress_port
flow_mod_msg.actions.add(act)
@@ -316,7 +316,7 @@
flow_mod_msg.buffer_id = 0xffffffff
flow_mod_msg.idle_timeout = 0
flow_mod_msg.hard_timeout = 0
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = egress_port
flow_mod_msg.actions.add(act)
@@ -474,7 +474,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
# build flow
ingress_port = of_ports[0];
diff --git a/tests/load.py b/tests/load.py
index 066f553..ed90dbf 100644
--- a/tests/load.py
+++ b/tests/load.py
@@ -58,7 +58,7 @@
match = packet_to_flow_match(self, pkt)
match.wildcards &= ~ofp.OFPFW_IN_PORT
match.in_port = lb_port
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = lb_port + 1
request = ofp.message.flow_mod()
@@ -68,7 +68,7 @@
request.buffer_id = 0xffffffff
request.actions.add(act)
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = ofp.OFPP_CONTROLLER
request.actions.add(act)
@@ -79,7 +79,7 @@
msg = ofp.message.packet_out()
msg.in_port = lb_port
msg.data = str(pkt)
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = lb_port + 1
msg.actions.add(act)
logging.info("Sleeping before starting storm")
@@ -168,7 +168,7 @@
msg = ofp.message.packet_out()
msg.in_port = ofp.OFPP_NONE
msg.data = str(outpkt)
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = dp_port
msg.actions.add(act)
@@ -213,7 +213,7 @@
match.wildcards = ofp.OFPFW_ALL & ~ofp.OFPFW_DL_VLAN & ~ofp.OFPFW_DL_DST
match.dl_vlan = ofp.OFP_VLAN_NONE
match.dl_dst = [0, 1, 2, 3, i / 256, i % 256]
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = ofp.OFPP_CONTROLLER
request = ofp.message.flow_mod()
request.command = ofp.OFPFC_ADD
diff --git a/tests/message_types.py b/tests/message_types.py
index b557b7e..c05ea6a 100644
--- a/tests/message_types.py
+++ b/tests/message_types.py
@@ -361,7 +361,7 @@
request = ofp.message.flow_mod()
request.match = match
request.buffer_id = 0xffffffff
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = ofp.OFPP_CONTROLLER
act.max_len = bytes
request.actions.add(act)
@@ -459,7 +459,7 @@
#Insert a flow entry with action output to controller
request = ofp.message.flow_mod()
request.match = match
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = ofp.OFPP_CONTROLLER
act.max_len = 65535 # Send the complete packet and do not buffer
request.actions.add(act)
diff --git a/tests/nicira_dec_ttl.py b/tests/nicira_dec_ttl.py
index 013eae7..32d3501 100644
--- a/tests/nicira_dec_ttl.py
+++ b/tests/nicira_dec_ttl.py
@@ -7,19 +7,19 @@
from oftest.testutils import *
-class action_nx_dec_ttl(ofp.action.action_vendor):
+class action_nx_dec_ttl(ofp.action.vendor):
def __init__(self):
- ofp.action.action_vendor.__init__(self)
+ ofp.action.vendor.__init__(self)
self.vendor = 0x00002320
def pack(self):
- return ofp.action.action_vendor.pack(self) + struct.pack("!HHL", 18, 0x0, 0x0)
+ return ofp.action.vendor.pack(self) + struct.pack("!HHL", 18, 0x0, 0x0)
def __len__(self):
return 16
def show(self, prefix=''):
- return prefix + 'dec_ttl: ' + '\n' + ofp.action.action_vendor.show(self)
+ return prefix + 'dec_ttl: ' + '\n' + ofp.action.vendor.show(self)
@nonstandard
class TtlDecrement(base_tests.SimpleDataPlane):
diff --git a/tests/openflow_protocol_messages.py b/tests/openflow_protocol_messages.py
index 18a0396..028d939 100644
--- a/tests/openflow_protocol_messages.py
+++ b/tests/openflow_protocol_messages.py
@@ -219,7 +219,7 @@
msg = ofp.message.packet_out()
msg.data = str(outpkt)
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = dp_port
msg.actions.add(act)
diff --git a/tests/pktact.py b/tests/pktact.py
index 9407292..dea77df 100644
--- a/tests/pktact.py
+++ b/tests/pktact.py
@@ -104,7 +104,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
for idx in range(len(of_ports)):
delete_all_flows(self.controller)
@@ -173,7 +173,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
delete_all_flows(self.controller)
@@ -251,7 +251,7 @@
(queue_stats, p) = self.controller.transact(request)
self.assertNotEqual(queue_stats, None, "Queue stats request failed")
- act = ofp.action.action_enqueue()
+ act = ofp.action.enqueue()
for idx in range(len(of_ports)):
ingress_port = of_ports[idx]
@@ -376,7 +376,7 @@
skip_message_emit(self, "Enqueue packet to controller")
return
- act = ofp.action.action_enqueue()
+ act = ofp.action.enqueue()
for idx in range(len(of_ports)):
ingress_port = of_ports[idx]
@@ -501,7 +501,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
for idx in range(len(of_ports)):
delete_all_flows(self.controller)
@@ -559,7 +559,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
for ingress_port in of_ports:
delete_all_flows(self.controller)
@@ -611,7 +611,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
for ingress_port in of_ports:
delete_all_flows(self.controller)
@@ -659,7 +659,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
for of_port in of_ports:
# Clear relevant bits that might block ports
@@ -713,7 +713,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
for ingress_port in of_ports:
delete_all_flows(self.controller)
@@ -758,7 +758,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
for ingress_port in of_ports:
delete_all_flows(self.controller)
@@ -804,7 +804,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
for ingress_port in of_ports:
delete_all_flows(self.controller)
@@ -851,7 +851,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
# Clear OFPPC_NO_FLOOD on each port
for of_port in of_ports:
@@ -1263,7 +1263,7 @@
pkt = simple_tcp_packet(pktlen=len)
exp_pkt = simple_tcp_packet(pktlen=len_w_vid, dl_vlan_enable=True,
dl_vlan=new_vid)
- vid_act = ofp.action.action_set_vlan_vid()
+ vid_act = ofp.action.set_vlan_vid()
vid_act.vlan_vid = new_vid
flow_match_test(self, config["port_map"], pkt=pkt,
@@ -1318,7 +1318,7 @@
pkt = simple_tcp_packet(dl_vlan_enable=True, dl_vlan=old_vid)
exp_pkt = simple_tcp_packet(dl_vlan_enable=True, dl_vlan=new_vid)
- vid_act = ofp.action.action_set_vlan_vid()
+ vid_act = ofp.action.set_vlan_vid()
vid_act.vlan_vid = new_vid
flow_match_test(self, config["port_map"], pkt=pkt, exp_pkt=exp_pkt,
@@ -1362,7 +1362,7 @@
dl_vlan=new_vid)
wildcards = (required_wildcards(self) | ofp.OFPFW_DL_VLAN |
ofp.OFPFW_DL_VLAN_PCP)
- vid_act = ofp.action.action_set_vlan_vid()
+ vid_act = ofp.action.set_vlan_vid()
vid_act.vlan_vid = new_vid
request = flow_msg_create(self, untagged_pkt, ing_port=ing_port,
wildcards=wildcards, egr_ports=egr_ports,
@@ -1394,7 +1394,7 @@
pkt = simple_tcp_packet(dl_vlan_enable=True, dl_vlan=vid, dl_vlan_pcp=old_vlan_pcp)
exp_pkt = simple_tcp_packet(dl_vlan_enable=True, dl_vlan=vid, dl_vlan_pcp=new_vlan_pcp)
- vid_act = ofp.action.action_set_vlan_pcp()
+ vid_act = ofp.action.set_vlan_pcp()
vid_act.vlan_pcp = new_vlan_pcp
flow_match_test(self, config["port_map"], pkt=pkt, exp_pkt=exp_pkt,
@@ -1416,7 +1416,7 @@
pkt = simple_tcp_packet(pktlen=len_w_vid, dl_vlan_enable=True,
dl_vlan=old_vid)
exp_pkt = simple_tcp_packet(pktlen=len)
- vid_act = ofp.action.action_strip_vlan()
+ vid_act = ofp.action.strip_vlan()
flow_match_test(self, config["port_map"], pkt=pkt, exp_pkt=exp_pkt,
action_list=[vid_act])
@@ -1440,7 +1440,7 @@
exp_pkt = simple_tcp_packet(pktlen=len_untagged)
wildcards = (required_wildcards(self) | ofp.OFPFW_DL_VLAN |
ofp.OFPFW_DL_VLAN_PCP)
- vid_act = ofp.action.action_strip_vlan()
+ vid_act = ofp.action.strip_vlan()
flow_match_test(self, config["port_map"],
wildcards=wildcards,
@@ -1749,8 +1749,8 @@
logging.info("Running flow toggle with %d flows, %d iterations" %
(flow_count, iter_count))
acts = []
- acts.append(ofp.action.action_output())
- acts.append(ofp.action.action_output())
+ acts.append(ofp.action.output())
+ acts.append(ofp.action.output())
of_ports = config["port_map"].keys()
if len(of_ports) < 3:
@@ -1945,7 +1945,7 @@
request.match = match
request.buffer_id = 0xffffffff
request.priority = priority
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = output_port
request.actions.add(act)
logging.info("Inserting flow")
@@ -2091,7 +2091,7 @@
request2.match.in_port = ingress_port
request2.priority = 0
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = ofp.OFPP_IN_PORT
request2.actions.add(act)
self.controller.message_send(request2)
@@ -2181,7 +2181,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
def testPacket(title, pkt, result):
- act = ofp.action.action_output()
+ act = ofp.action.output()
pkts = [
[title, pkt, result]
]
@@ -2377,7 +2377,7 @@
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
match.wildcards &= ~ofp.OFPFW_IN_PORT
- act = ofp.action.action_output()
+ act = ofp.action.output()
self.testPktsAgainstFlow(
[[
@@ -2413,7 +2413,7 @@
scapy.Ether(dst=dl_dst, src=dl_src, type=len(llc)) / llc,
self.RESULT_MATCH,
]],
- ofp.action.action_output(), match
+ ofp.action.output(), match
)
# Corrupt length field
@@ -2424,7 +2424,7 @@
scapy.Ether(dst=dl_dst, src=dl_src, type=ethLen) / llc,
self.RESULT_ANY,
]],
- ofp.action.action_output(), match
+ ofp.action.output(), match
)
def testPacketEthSrcDstTypeMatch(title, llc, is_snap_ip):
@@ -2446,7 +2446,7 @@
scapy.Ether(dst=dl_dst, src=dl_src, type=len(llc)) / llc,
is_match,
]],
- ofp.action.action_output(), match
+ ofp.action.output(), match
)
# Corrupt length field
@@ -2457,7 +2457,7 @@
scapy.Ether(dst=dl_dst, src=dl_src, type=ethLen) / llc,
self.RESULT_ANY,
]],
- ofp.action.action_output(), match
+ ofp.action.output(), match
)
def testPacket(title, llc, is_snap_ip):
@@ -2539,7 +2539,7 @@
scapy.Ether(dst=dl_dst, src=dl_src, type=len(llc)) / llc,
result,
])
- act = ofp.action.action_output()
+ act = ofp.action.output()
self.testPktsAgainstFlow(pkts, act, match)
def testPacketEthTypeNotEth(title, llc, is_snap):
@@ -2559,7 +2559,7 @@
scapy.Ether(dst=dl_dst, src=dl_src, type=len(llc)) / llc,
result,
])
- act = ofp.action.action_output()
+ act = ofp.action.output()
self.testPktsAgainstFlow(pkts, act, match)
def testPacket(title, llc, is_snap):
@@ -2648,7 +2648,7 @@
result,
])
- act = ofp.action.action_output()
+ act = ofp.action.output()
self.testPktsAgainstFlow(pkts, act, match)
testPacket("Basic ARP",
@@ -2693,7 +2693,7 @@
result,
])
- act = ofp.action.action_output()
+ act = ofp.action.output()
self.testPktsAgainstFlow(pkts, act, match)
testPacket("Basic MAC matching - IPv4 payload",
@@ -2790,7 +2790,7 @@
result,
])
- act = ofp.action.action_output()
+ act = ofp.action.output()
self.testPktsAgainstFlow(pkts, act, match)
testPacket("Ether matching with double VLAN tag - Wrong type match",
self.createMatch(dl_dst=parse_mac(dl_dst), dl_src=parse_mac(dl_src),
diff --git a/tests/port_stats.py b/tests/port_stats.py
index 4aaf4ed..8aeefa4 100644
--- a/tests/port_stats.py
+++ b/tests/port_stats.py
@@ -155,7 +155,7 @@
match.wildcards &= ~ofp.OFPFW_IN_PORT
self.assertTrue(match is not None,
"Could not generate flow match from pkt")
- act = ofp.action.action_output()
+ act = ofp.action.output()
# build flow
ingress_port = of_ports[0];
@@ -214,7 +214,7 @@
flow_mod_msg.buffer_id = 0xffffffff
flow_mod_msg.idle_timeout = 0
flow_mod_msg.hard_timeout = 0
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = egress_port
flow_mod_msg.actions.add(act)
@@ -291,7 +291,7 @@
flow_mod_msg.buffer_id = 0xffffffff
flow_mod_msg.idle_timeout = 0
flow_mod_msg.hard_timeout = 0
- act = ofp.action.action_output()
+ act = ofp.action.output()
act.port = egress_port
flow_mod_msg.actions.add(act)