test suite reviews and discussions
 help / color / mirror / Atom feed
* [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule priority
@ 2021-09-15  5:39 Jiale Song
  2021-09-15  5:39 ` [dts] [PATCH V2 2/2] tests/cvl_dcf_flow_priority: modify the script according to the testplan Jiale Song
  2021-09-27  6:31 ` [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule priority Tu, Lijuan
  0 siblings, 2 replies; 5+ messages in thread
From: Jiale Song @ 2021-09-15  5:39 UTC (permalink / raw)
  To: dts; +Cc: Jiale Song

because the priority of the dpdk rule is changed from 0<1<2... to 0>1>2..., 
modify the testplan

Signed-off-by: Jiale Song <songx.jiale@intel.com>
---
 .../cvl_dcf_flow_priority_test_plan.rst       | 26 +++++++++----------
 1 file changed, 13 insertions(+), 13 deletions(-)
 mode change 100644 => 100755 test_plans/cvl_dcf_flow_priority_test_plan.rst

diff --git a/test_plans/cvl_dcf_flow_priority_test_plan.rst b/test_plans/cvl_dcf_flow_priority_test_plan.rst
old mode 100644
new mode 100755
index 8ae6052..38e86a7
--- a/test_plans/cvl_dcf_flow_priority_test_plan.rst
+++ b/test_plans/cvl_dcf_flow_priority_test_plan.rst
@@ -118,16 +118,16 @@ test steps for supported pattern
 ================================
 1. validate rules: two rules have same pattern, input set but different priority and action(priority 0 -> to vf 1, priority 1 -> to vf 2).
 2. create rules and list rules.
-3. send matched packets, check vf 2 receive the packets for hiting the priority 1.
+3. send matched packets, check vf 1 receive the packets for hiting the priority 0.
 4. send mismatched packets, check the packets are not received by vf 1 or 2.
-5. destroy rule with priority 1, list rules.
-6. send matched packets, check vf 1 receive the packets for hiting the priority 0.
+5. destroy rule with priority 0, list rules.
+6. send matched packets, check vf 2 receive the packets for hiting the priority 1.
 7. send mismatched packets, check the packets are not received by vf 1 or 2.
-8. recreate rules which priority is 1, list rule.
-9. destroy rule with priority 0, list rules.
-10. send matched packets, check vf 2 receive the packets for hiting the priority 1.
+8. recreate rules which priority is 0, list rule.
+9. destroy rule with priority 1, list rules.
+10. send matched packets, check vf 1 receive the packets for hiting the priority 0.
 11. send mismatched packets, check the packets are not received by vf 1 or 2.
-12. destroy rule with priority 1, list rules.
+12. destroy rule with priority 0, list rules.
 13. send matched packets, check the packets are not received by vf 1 or 2.
 
 
@@ -1745,12 +1745,12 @@ subcase 3: some rules overlap
 -----------------------------
 1. create rules::
 
-    flow create 0 priority 0 ingress pattern eth / vlan / vlan / pppoes / pppoe_proto_id is 0x21 / end actions vf id 1 / end
-    flow create 0 priority 0 ingress pattern eth / vlan / vlan tci is 2 / end actions vf id 1 / end
-    flow create 0 priority 1 ingress pattern eth / vlan / vlan / pppoes seid is 1 / ipv4 / end actions vf id 2 / end
-    flow create 0 priority 1 ingress pattern eth dst is 00:00:00:01:03:03 / vlan / vlan / end actions vf id 2 / end
-    flow create 0 priority 1 ingress pattern eth dst is 00:00:00:01:03:03 / end actions vf id 3 / end
-    flow create 0 priority 1 ingress pattern eth / vlan tci is 1 / vlan tci is 2 / end actions vf id 3 / end
+    flow create 0 priority 1 ingress pattern eth / vlan / vlan / pppoes / pppoe_proto_id is 0x21 / end actions vf id 1 / end
+    flow create 0 priority 1 ingress pattern eth / vlan / vlan tci is 2 / end actions vf id 1 / end
+    flow create 0 priority 0 ingress pattern eth / vlan / vlan / pppoes seid is 1 / ipv4 / end actions vf id 2 / end
+    flow create 0 priority 0 ingress pattern eth dst is 00:00:00:01:03:03 / vlan / vlan / end actions vf id 2 / end
+    flow create 0 priority 0 ingress pattern eth dst is 00:00:00:01:03:03 / end actions vf id 3 / end
+    flow create 0 priority 0 ingress pattern eth / vlan tci is 1 / vlan tci is 2 / end actions vf id 3 / end
 
 2. check all the rules exist in the list::
 
-- 
2.17.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [dts] [PATCH V2 2/2] tests/cvl_dcf_flow_priority: modify the script according to the testplan
  2021-09-15  5:39 [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule priority Jiale Song
@ 2021-09-15  5:39 ` Jiale Song
  2021-10-22  9:22   ` Tu, Lijuan
  2021-09-27  6:31 ` [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule priority Tu, Lijuan
  1 sibling, 1 reply; 5+ messages in thread
From: Jiale Song @ 2021-09-15  5:39 UTC (permalink / raw)
  To: dts; +Cc: Jiale Song

Signed-off-by: Jiale Song <songx.jiale@intel.com>
---
 tests/TestSuite_cvl_dcf_flow_priority.py | 48 ++++++++++++------------
 1 file changed, 25 insertions(+), 23 deletions(-)
 mode change 100644 => 100755 tests/TestSuite_cvl_dcf_flow_priority.py

diff --git a/tests/TestSuite_cvl_dcf_flow_priority.py b/tests/TestSuite_cvl_dcf_flow_priority.py
old mode 100644
new mode 100755
index 07d99d2..8e38df9
--- a/tests/TestSuite_cvl_dcf_flow_priority.py
+++ b/tests/TestSuite_cvl_dcf_flow_priority.py
@@ -1278,8 +1278,8 @@ class CVLDCFFlowPriorityTest(TestCase):
             res = filter(bool, map(p_spec.match, out_lines))
             result = [i.group(1) for i in res]
         if need_verify:
-            self.verify(result == rule_list,
-                    "the rule list is not the same. expect %s, result %s" % (rule_list, result))
+            self.verify(sorted(result) == rule_list,
+                    "the rule list is not the same. expect %s, result %s" % (rule_list, sorted(result)))
         else:
             return result
 
@@ -1320,6 +1320,7 @@ class CVLDCFFlowPriorityTest(TestCase):
         rule1=rte_flow_pattern[0:14] + "priority 0" + rte_flow_pattern[13:length]
         rule2=rte_flow_pattern[0:14] + "priority 1" + rte_flow_pattern[13:length-7]+ "2" + rte_flow_pattern[length-6:length]
         rte_flow=[rule1, rule2]
+
         #validate 2 rule
         self.validate_switch_filter_rule(rte_flow)
         #create 2 rule
@@ -1327,31 +1328,34 @@ class CVLDCFFlowPriorityTest(TestCase):
         self.check_switch_filter_rule_list(0, rule_list)
         #send matched packets and check
         matched_dic = test_vector["matched"]
-        matched_dic["check_func"]["param"]["expect_port"]=2
         self.send_and_check_packets(matched_dic)
         #send mismatched packets and check
         mismatched_dic = test_vector["mismatched"]
         mismatched_dic["check_func"]["param"]["expect_port"]=[1,2]
         mismatched_dic["expect_results"]["expect_pkts"]=[0,0]
         self.send_and_check_packets(mismatched_dic)
-        #destroy rule with priority 1
-        self.destroy_switch_filter_rule(0, rule_list[1])
-        self.check_switch_filter_rule_list(0, ['0'])
-        #send matched packets and check
-        destroy_dict1 = copy.deepcopy(matched_dic)
-        destroy_dict1["check_func"]["param"]["expect_port"]=1
-        self.send_and_check_packets(destroy_dict1)
-        #recreate rule with priority 1
-        self.create_switch_filter_rule(rte_flow[1])
-        self.check_switch_filter_rule_list(0, rule_list)
+
         #destroy rule with priority 0
         self.destroy_switch_filter_rule(0, rule_list[0])
+        rule_list.remove('0')
         self.check_switch_filter_rule_list(0, ['1'])
         #send matched packets and check
+        destroy_dict1 = copy.deepcopy(matched_dic)
+        destroy_dict1["check_func"]["param"]["expect_port"]=2
+        self.send_and_check_packets(destroy_dict1)
+
+        #recreate rule with priority 0 (rule 2)
+        self.create_switch_filter_rule(rte_flow[0])
+        rule_list.insert(0, '2')
+        #destroy rule with priority 1
+        self.destroy_switch_filter_rule(0, rule_list[1])
+        self.check_switch_filter_rule_list(0, ['2'])
+        #send matched packets and check
         destroy_dict2 = copy.deepcopy(matched_dic)
         self.send_and_check_packets(destroy_dict2)
-        #destroy rule with priority 1 and check
-        self.destroy_switch_filter_rule(0, rule_list[1])
+
+        #destroy rule with priority 0 and check
+        self.destroy_switch_filter_rule(0, rule_list[0])
         self.check_switch_filter_rule_list(0, [])
         destroy_dict3 = copy.deepcopy(matched_dic)
         if isinstance(destroy_dict3["expect_results"]["expect_pkts"], list):
@@ -1679,7 +1683,6 @@ class CVLDCFFlowPriorityTest(TestCase):
         rule=["flow create 0 priority 1 ingress pattern eth / ipv4 src is 192.168.0.1 dst is 192.168.0.2 / end actions vf id 2 / end",
                    "flow create 0 priority 0 ingress pattern eth / ipv4 src is 192.168.0.1 dst is 192.168.0.2 / end actions vf id 2 / end"]
         rule_list=self.create_switch_filter_rule(rule)
-        #self.check_switch_filter_rule_list(0, rule_list)
         matched_dic = {"scapy_str":['Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/("X"*480)'],
                        "check_func":{"func":rfc.check_vf_rx_packets_number,
                                      "param":{"expect_port":2, "expect_queue":"null"}},
@@ -1694,7 +1697,6 @@ class CVLDCFFlowPriorityTest(TestCase):
         rule=["flow create 0 priority 1 ingress pattern eth / ipv4 src is 192.168.0.1 dst is 192.168.0.2 / end actions vf id 1 / end",
                    "flow create 0 priority 1 ingress pattern eth / ipv4 src is 192.168.0.1 dst is 192.168.0.2 / end actions vf id 2 / end"]
         rule_list=self.create_switch_filter_rule(rule)
-        self.check_switch_filter_rule_list(0, rule_list)
         matched_dic = {"scapy_str":['Ether(dst="68:05:ca:8d:ed:a8")/IP(src="192.168.0.1",dst="192.168.0.2",tos=4,ttl=2)/TCP()/("X"*480)'],
                        "check_func":{"func":rfc.check_vf_rx_packets_number,
                                      "param":{"expect_port":[1,2], "expect_queue":"null"}},
@@ -1706,12 +1708,12 @@ class CVLDCFFlowPriorityTest(TestCase):
 
         #subcase 3: some rules overlap
         self.launch_testpmd()
-        rule=["flow create 0 priority 0 ingress pattern eth / vlan / vlan / pppoes / pppoe_proto_id is 0x21 / end actions vf id 1 / end",
-                   "flow create 0 priority 0 ingress pattern eth / vlan / vlan tci is 2 / end actions vf id 1 / end",
-                   "flow create 0 priority 1 ingress pattern eth / vlan / vlan / pppoes seid is 1 / ipv4 / end actions vf id 2 / end",
-                   "flow create 0 priority 1 ingress pattern eth dst is 00:00:00:01:03:03 / vlan / vlan / end actions vf id 2 / end",
-                   "flow create 0 priority 1 ingress pattern eth dst is 00:00:00:01:03:03 / end actions vf id 3 / end",
-                   "flow create 0 priority 1 ingress pattern eth / vlan tci is 1 / vlan tci is 2 / end actions vf id 3 / end"]
+        rule=["flow create 0 priority 1 ingress pattern eth / vlan / vlan / pppoes / pppoe_proto_id is 0x21 / end actions vf id 1 / end",
+                   "flow create 0 priority 1 ingress pattern eth / vlan / vlan tci is 2 / end actions vf id 1 / end",
+                   "flow create 0 priority 0 ingress pattern eth / vlan / vlan / pppoes seid is 1 / ipv4 / end actions vf id 2 / end",
+                   "flow create 0 priority 0 ingress pattern eth dst is 00:00:00:01:03:03 / vlan / vlan / end actions vf id 2 / end",
+                   "flow create 0 priority 0 ingress pattern eth dst is 00:00:00:01:03:03 / end actions vf id 3 / end",
+                   "flow create 0 priority 0 ingress pattern eth / vlan tci is 1 / vlan tci is 2 / end actions vf id 3 / end"]
         rule_list=self.create_switch_filter_rule(rule)
         self.check_switch_filter_rule_list(0, rule_list)
         matched_dic = {"scapy_str":['Ether(dst="00:00:00:01:03:03")/Dot1Q(vlan=1)/Dot1Q(vlan=2)/Raw("x"*480)'],
-- 
2.17.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule priority
  2021-09-15  5:39 [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule priority Jiale Song
  2021-09-15  5:39 ` [dts] [PATCH V2 2/2] tests/cvl_dcf_flow_priority: modify the script according to the testplan Jiale Song
@ 2021-09-27  6:31 ` Tu, Lijuan
  2021-10-20  9:47   ` Huang, ZhiminX
  1 sibling, 1 reply; 5+ messages in thread
From: Tu, Lijuan @ 2021-09-27  6:31 UTC (permalink / raw)
  To: Jiale, SongX, dts; +Cc: Jiale, SongX

> -----Original Message-----
> From: dts <dts-bounces@dpdk.org> On Behalf Of Jiale Song
> Sent: 2021年9月15日 13:40
> To: dts@dpdk.org
> Cc: Jiale, SongX <songx.jiale@intel.com>
> Subject: [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule
> priority
> 
> because the priority of the dpdk rule is changed from 0<1<2... to 0>1>2...,
> modify the testplan
> 
> Signed-off-by: Jiale Song <songx.jiale@intel.com>

Could you please provide me dpdk commit ?

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule priority
  2021-09-27  6:31 ` [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule priority Tu, Lijuan
@ 2021-10-20  9:47   ` Huang, ZhiminX
  0 siblings, 0 replies; 5+ messages in thread
From: Huang, ZhiminX @ 2021-10-20  9:47 UTC (permalink / raw)
  To: Tu, Lijuan, dts; +Cc: Jiale, SongX

> -----Original Message-----
> From: dts <dts-bounces@dpdk.org> On Behalf Of Tu, Lijuan
> Sent: Monday, September 27, 2021 2:32 PM
> To: Jiale, SongX <songx.jiale@intel.com>; dts@dpdk.org
> Cc: Jiale, SongX <songx.jiale@intel.com>
> Subject: Re: [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule
> priority
> 
> > -----Original Message-----
> > From: dts <dts-bounces@dpdk.org> On Behalf Of Jiale Song
> > Sent: 2021年9月15日 13:40
> > To: dts@dpdk.org
> > Cc: Jiale, SongX <songx.jiale@intel.com>
> > Subject: [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify
> > rule priority
> >
> > because the priority of the dpdk rule is changed from 0<1<2... to
> > 0>1>2..., modify the testplan
> >
> > Signed-off-by: Jiale Song <songx.jiale@intel.com>
> 
> Could you please provide me dpdk commit ?

According to dpdk commit 72908beba944b57e3e1cbe0edf7728a192230d2b, modified testplan.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dts] [PATCH V2 2/2] tests/cvl_dcf_flow_priority: modify the script according to the testplan
  2021-09-15  5:39 ` [dts] [PATCH V2 2/2] tests/cvl_dcf_flow_priority: modify the script according to the testplan Jiale Song
@ 2021-10-22  9:22   ` Tu, Lijuan
  0 siblings, 0 replies; 5+ messages in thread
From: Tu, Lijuan @ 2021-10-22  9:22 UTC (permalink / raw)
  To: Jiale, SongX, dts; +Cc: Jiale, SongX

> -----Original Message-----
> From: dts <dts-bounces@dpdk.org> On Behalf Of Jiale Song
> Sent: 2021年9月15日 13:40
> To: dts@dpdk.org
> Cc: Jiale, SongX <songx.jiale@intel.com>
> Subject: [dts] [PATCH V2 2/2] tests/cvl_dcf_flow_priority: modify the script
> according to the testplan
> 
> Signed-off-by: Jiale Song <songx.jiale@intel.com>

Applied, thanks

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-10-22  9:22 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-15  5:39 [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule priority Jiale Song
2021-09-15  5:39 ` [dts] [PATCH V2 2/2] tests/cvl_dcf_flow_priority: modify the script according to the testplan Jiale Song
2021-10-22  9:22   ` Tu, Lijuan
2021-09-27  6:31 ` [dts] [PATCH V2 1/2] test_plans/cvl_dcf_flow_priority: modify rule priority Tu, Lijuan
2021-10-20  9:47   ` Huang, ZhiminX

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).