* [dts] [PATCH] tests: change checking method for queue-region rule.
@ 2018-12-28 10:10 Peng Yuan
2018-12-29 16:24 ` Lijuan Tu
0 siblings, 1 reply; 4+ messages in thread
From: Peng Yuan @ 2018-12-28 10:10 UTC (permalink / raw)
To: dts; +Cc: Peng Yuan
change the checking method of result when flushed the queue-region rules.
Signed-off-by: Peng Yuan <yuan.peng@intel.com>
diff --git a/tests/TestSuite_queue_region.py b/tests/TestSuite_queue_region.py
index e971c46..5f4dbf4 100644
--- a/tests/TestSuite_queue_region.py
+++ b/tests/TestSuite_queue_region.py
@@ -109,6 +109,7 @@ class TestQueue_region(TestCase):
self.send_packet_up(mac, pkt_type, prio)
queue = self.get_queue_number()
self.verify(queue in queue_region, "the packet doesn't enter the expected queue region.")
+ return queue
def send_packet_pctype(self, mac, pkt_type="udp", frag=0, flags=None, tag=None, ethertype=None):
"""
@@ -230,7 +231,7 @@ class TestQueue_region(TestCase):
# 7 | 10 | 46 | Frag_IPv6
# send the packets and verify the results
queue_region = ["1"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp")
+ queue_udp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp")
# fortville can't parse the TCP SYN type packet, fortpark can parse it.
if(self.nic in ["fortpark_TLV"]):
@@ -245,10 +246,10 @@ class TestQueue_region(TestCase):
# not assign ipv4-sctp packet to any queue region, the packet to queue region 0.
queue_region = ["1"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="sctp", tag=1)
+ queue_sctp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="sctp", tag=1)
queue_region = ["11", "12", "13", "14"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv4")
+ queue_ipv4 = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv4")
queue_region = ["5"]
self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv4", frag=1)
@@ -258,10 +259,10 @@ class TestQueue_region(TestCase):
# not assign ipv4-tcp SYN packet to any queue region, the packet to queue region 0.
if(self.nic in ["fortpark_TLV"]):
queue_region = ["1"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
+ queue_ipv6tcp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
else:
queue_region = ["8", "9"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
+ queue_ipv6tcp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
queue_region = ["11", "12", "13", "14"]
self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_sctp", tag=2)
@@ -287,19 +288,19 @@ class TestQueue_region(TestCase):
out = self.dut.send_expect("show port 0 queue-region", "testpmd> ")
self.get_and_compare_rules(out, 0, 0, 0)
- # confirm packet not to the same queue after flush all the queue region rull.
+ # confirm packet not to the same queue after flush all the queue regions rull.
self.send_packet_pctype(mac=self.pf_mac, pkt_type="udp")
queue = self.get_queue_number()
- self.verify(queue not in ["1"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_udp, "the queue regions have not been flushed clearly.")
self.send_packet_pctype(mac=self.pf_mac, pkt_type="sctp")
queue = self.get_queue_number()
- self.verify(queue not in ["1"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_sctp, "the queue regions have not been flushed clearly.")
self.send_packet_pctype(mac=self.pf_mac, pkt_type="ipv4")
queue = self.get_queue_number()
- self.verify(queue not in ["10", "11", "12", "13"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_ipv4, "the queue regions have not been flushed clearly.")
self.send_packet_pctype(mac=self.pf_mac, pkt_type="ipv6_tcp")
queue = self.get_queue_number()
- self.verify(queue not in ["8", "9"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_ipv6tcp, "the queue regions have not been flushed clearly.")
def test_up_map_queue_region(self):
# set queue region on a port
@@ -330,13 +331,13 @@ class TestQueue_region(TestCase):
self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_udp", prio=1)
queue_region = ["10", "11", "12", "13"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="tcp", prio=2)
+ queue_tcp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="tcp", prio=2)
queue_region = ["10", "11", "12", "13"]
self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="tcp", prio=7)
queue_region = ["10", "11", "12", "13"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp", prio=7)
+ queue_udp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp", prio=7)
self.send_packet_pctype(mac=self.pf_mac, pkt_type="udp")
queue = self.get_queue_number()
@@ -352,10 +353,10 @@ class TestQueue_region(TestCase):
# confirm packet not to the same queue after flush all the queue region rull.
self.send_packet_up(mac=self.pf_mac, pkt_type="udp", prio=7)
queue = self.get_queue_number()
- self.verify(queue not in ["10", "11", "12", "13"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_udp, "the queue regions have not been flushed clearly.")
self.send_packet_up(mac=self.pf_mac, pkt_type="tcp", prio=2)
queue = self.get_queue_number()
- self.verify(queue not in ["10", "11", "12", "13"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_tcp, "the queue regions have not been flushed clearly.")
def test_boundary_values(self):
# boundary value testing of "Set a queue region on a port"
--
2.5.0
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dts] [PATCH] tests: change checking method for queue-region rule.
2018-12-28 10:10 [dts] [PATCH] tests: change checking method for queue-region rule Peng Yuan
@ 2018-12-29 16:24 ` Lijuan Tu
0 siblings, 0 replies; 4+ messages in thread
From: Lijuan Tu @ 2018-12-29 16:24 UTC (permalink / raw)
To: Peng Yuan, dts
Applied, thanks
On 2018年12月28日 18:10, Peng Yuan wrote:
> change the checking method of result when flushed the queue-region rules.
>
> Signed-off-by: Peng Yuan <yuan.peng@intel.com>
>
> diff --git a/tests/TestSuite_queue_region.py b/tests/TestSuite_queue_region.py
> index e971c46..5f4dbf4 100644
> --- a/tests/TestSuite_queue_region.py
> +++ b/tests/TestSuite_queue_region.py
> @@ -109,6 +109,7 @@ class TestQueue_region(TestCase):
> self.send_packet_up(mac, pkt_type, prio)
> queue = self.get_queue_number()
> self.verify(queue in queue_region, "the packet doesn't enter the expected queue region.")
> + return queue
>
> def send_packet_pctype(self, mac, pkt_type="udp", frag=0, flags=None, tag=None, ethertype=None):
> """
> @@ -230,7 +231,7 @@ class TestQueue_region(TestCase):
> # 7 | 10 | 46 | Frag_IPv6
> # send the packets and verify the results
> queue_region = ["1"]
> - self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp")
> + queue_udp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp")
>
> # fortville can't parse the TCP SYN type packet, fortpark can parse it.
> if(self.nic in ["fortpark_TLV"]):
> @@ -245,10 +246,10 @@ class TestQueue_region(TestCase):
>
> # not assign ipv4-sctp packet to any queue region, the packet to queue region 0.
> queue_region = ["1"]
> - self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="sctp", tag=1)
> + queue_sctp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="sctp", tag=1)
>
> queue_region = ["11", "12", "13", "14"]
> - self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv4")
> + queue_ipv4 = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv4")
>
> queue_region = ["5"]
> self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv4", frag=1)
> @@ -258,10 +259,10 @@ class TestQueue_region(TestCase):
> # not assign ipv4-tcp SYN packet to any queue region, the packet to queue region 0.
> if(self.nic in ["fortpark_TLV"]):
> queue_region = ["1"]
> - self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
> + queue_ipv6tcp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
> else:
> queue_region = ["8", "9"]
> - self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
> + queue_ipv6tcp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
>
> queue_region = ["11", "12", "13", "14"]
> self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_sctp", tag=2)
> @@ -287,19 +288,19 @@ class TestQueue_region(TestCase):
> out = self.dut.send_expect("show port 0 queue-region", "testpmd> ")
> self.get_and_compare_rules(out, 0, 0, 0)
>
> - # confirm packet not to the same queue after flush all the queue region rull.
> + # confirm packet not to the same queue after flush all the queue regions rull.
> self.send_packet_pctype(mac=self.pf_mac, pkt_type="udp")
> queue = self.get_queue_number()
> - self.verify(queue not in ["1"], "the queue regions have not been flushed clearly.")
> + self.verify(queue != queue_udp, "the queue regions have not been flushed clearly.")
> self.send_packet_pctype(mac=self.pf_mac, pkt_type="sctp")
> queue = self.get_queue_number()
> - self.verify(queue not in ["1"], "the queue regions have not been flushed clearly.")
> + self.verify(queue != queue_sctp, "the queue regions have not been flushed clearly.")
> self.send_packet_pctype(mac=self.pf_mac, pkt_type="ipv4")
> queue = self.get_queue_number()
> - self.verify(queue not in ["10", "11", "12", "13"], "the queue regions have not been flushed clearly.")
> + self.verify(queue != queue_ipv4, "the queue regions have not been flushed clearly.")
> self.send_packet_pctype(mac=self.pf_mac, pkt_type="ipv6_tcp")
> queue = self.get_queue_number()
> - self.verify(queue not in ["8", "9"], "the queue regions have not been flushed clearly.")
> + self.verify(queue != queue_ipv6tcp, "the queue regions have not been flushed clearly.")
>
> def test_up_map_queue_region(self):
> # set queue region on a port
> @@ -330,13 +331,13 @@ class TestQueue_region(TestCase):
> self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_udp", prio=1)
>
> queue_region = ["10", "11", "12", "13"]
> - self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="tcp", prio=2)
> + queue_tcp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="tcp", prio=2)
>
> queue_region = ["10", "11", "12", "13"]
> self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="tcp", prio=7)
>
> queue_region = ["10", "11", "12", "13"]
> - self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp", prio=7)
> + queue_udp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp", prio=7)
>
> self.send_packet_pctype(mac=self.pf_mac, pkt_type="udp")
> queue = self.get_queue_number()
> @@ -352,10 +353,10 @@ class TestQueue_region(TestCase):
> # confirm packet not to the same queue after flush all the queue region rull.
> self.send_packet_up(mac=self.pf_mac, pkt_type="udp", prio=7)
> queue = self.get_queue_number()
> - self.verify(queue not in ["10", "11", "12", "13"], "the queue regions have not been flushed clearly.")
> + self.verify(queue != queue_udp, "the queue regions have not been flushed clearly.")
> self.send_packet_up(mac=self.pf_mac, pkt_type="tcp", prio=2)
> queue = self.get_queue_number()
> - self.verify(queue not in ["10", "11", "12", "13"], "the queue regions have not been flushed clearly.")
> + self.verify(queue != queue_tcp, "the queue regions have not been flushed clearly.")
>
> def test_boundary_values(self):
> # boundary value testing of "Set a queue region on a port"
^ permalink raw reply [flat|nested] 4+ messages in thread
* [dts] [PATCH] tests: change checking method for queue-region rule.
@ 2018-12-28 11:28 Peng Yuan
2018-12-29 1:35 ` Zhu, ShuaiX
0 siblings, 1 reply; 4+ messages in thread
From: Peng Yuan @ 2018-12-28 11:28 UTC (permalink / raw)
To: dts; +Cc: Peng Yuan
change the checking method of result when flushed the queue-region rules.
Signed-off-by: Peng Yuan <yuan.peng@intel.com>
diff --git a/tests/TestSuite_queue_region.py b/tests/TestSuite_queue_region.py
index e971c46..5f4dbf4 100644
--- a/tests/TestSuite_queue_region.py
+++ b/tests/TestSuite_queue_region.py
@@ -109,6 +109,7 @@ class TestQueue_region(TestCase):
self.send_packet_up(mac, pkt_type, prio)
queue = self.get_queue_number()
self.verify(queue in queue_region, "the packet doesn't enter the expected queue region.")
+ return queue
def send_packet_pctype(self, mac, pkt_type="udp", frag=0, flags=None, tag=None, ethertype=None):
"""
@@ -230,7 +231,7 @@ class TestQueue_region(TestCase):
# 7 | 10 | 46 | Frag_IPv6
# send the packets and verify the results
queue_region = ["1"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp")
+ queue_udp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp")
# fortville can't parse the TCP SYN type packet, fortpark can parse it.
if(self.nic in ["fortpark_TLV"]):
@@ -245,10 +246,10 @@ class TestQueue_region(TestCase):
# not assign ipv4-sctp packet to any queue region, the packet to queue region 0.
queue_region = ["1"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="sctp", tag=1)
+ queue_sctp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="sctp", tag=1)
queue_region = ["11", "12", "13", "14"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv4")
+ queue_ipv4 = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv4")
queue_region = ["5"]
self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv4", frag=1)
@@ -258,10 +259,10 @@ class TestQueue_region(TestCase):
# not assign ipv4-tcp SYN packet to any queue region, the packet to queue region 0.
if(self.nic in ["fortpark_TLV"]):
queue_region = ["1"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
+ queue_ipv6tcp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
else:
queue_region = ["8", "9"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
+ queue_ipv6tcp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_tcp")
queue_region = ["11", "12", "13", "14"]
self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_sctp", tag=2)
@@ -287,19 +288,19 @@ class TestQueue_region(TestCase):
out = self.dut.send_expect("show port 0 queue-region", "testpmd> ")
self.get_and_compare_rules(out, 0, 0, 0)
- # confirm packet not to the same queue after flush all the queue region rull.
+ # confirm packet not to the same queue after flush all the queue regions rull.
self.send_packet_pctype(mac=self.pf_mac, pkt_type="udp")
queue = self.get_queue_number()
- self.verify(queue not in ["1"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_udp, "the queue regions have not been flushed clearly.")
self.send_packet_pctype(mac=self.pf_mac, pkt_type="sctp")
queue = self.get_queue_number()
- self.verify(queue not in ["1"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_sctp, "the queue regions have not been flushed clearly.")
self.send_packet_pctype(mac=self.pf_mac, pkt_type="ipv4")
queue = self.get_queue_number()
- self.verify(queue not in ["10", "11", "12", "13"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_ipv4, "the queue regions have not been flushed clearly.")
self.send_packet_pctype(mac=self.pf_mac, pkt_type="ipv6_tcp")
queue = self.get_queue_number()
- self.verify(queue not in ["8", "9"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_ipv6tcp, "the queue regions have not been flushed clearly.")
def test_up_map_queue_region(self):
# set queue region on a port
@@ -330,13 +331,13 @@ class TestQueue_region(TestCase):
self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="ipv6_udp", prio=1)
queue_region = ["10", "11", "12", "13"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="tcp", prio=2)
+ queue_tcp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="tcp", prio=2)
queue_region = ["10", "11", "12", "13"]
self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="tcp", prio=7)
queue_region = ["10", "11", "12", "13"]
- self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp", prio=7)
+ queue_udp = self.send_and_check(queue_region, mac=self.pf_mac, pkt_type="udp", prio=7)
self.send_packet_pctype(mac=self.pf_mac, pkt_type="udp")
queue = self.get_queue_number()
@@ -352,10 +353,10 @@ class TestQueue_region(TestCase):
# confirm packet not to the same queue after flush all the queue region rull.
self.send_packet_up(mac=self.pf_mac, pkt_type="udp", prio=7)
queue = self.get_queue_number()
- self.verify(queue not in ["10", "11", "12", "13"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_udp, "the queue regions have not been flushed clearly.")
self.send_packet_up(mac=self.pf_mac, pkt_type="tcp", prio=2)
queue = self.get_queue_number()
- self.verify(queue not in ["10", "11", "12", "13"], "the queue regions have not been flushed clearly.")
+ self.verify(queue != queue_tcp, "the queue regions have not been flushed clearly.")
def test_boundary_values(self):
# boundary value testing of "Set a queue region on a port"
--
2.5.0
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dts] [PATCH] tests: change checking method for queue-region rule.
2018-12-28 11:28 Peng Yuan
@ 2018-12-29 1:35 ` Zhu, ShuaiX
0 siblings, 0 replies; 4+ messages in thread
From: Zhu, ShuaiX @ 2018-12-29 1:35 UTC (permalink / raw)
To: Peng, Yuan, dts; +Cc: Peng, Yuan, Zhu, ShuaiX
Tested-by:Zhu, ShuaiX <shuaix.zhu@intel.com>
> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of Peng Yuan
> Sent: Friday, December 28, 2018 7:28 PM
> To: dts@dpdk.org
> Cc: Peng, Yuan <yuan.peng@intel.com>
> Subject: [dts] [PATCH] tests: change checking method for queue-region rule.
>
> change the checking method of result when flushed the queue-region rules.
>
> Signed-off-by: Peng Yuan <yuan.peng@intel.com>
>
> diff --git a/tests/TestSuite_queue_region.py
> b/tests/TestSuite_queue_region.py index e971c46..5f4dbf4 100644
> --- a/tests/TestSuite_queue_region.py
> +++ b/tests/TestSuite_queue_region.py
> @@ -109,6 +109,7 @@ class TestQueue_region(TestCase):
> self.send_packet_up(mac, pkt_type, prio)
> queue = self.get_queue_number()
> self.verify(queue in queue_region, "the packet doesn't enter the
> expected queue region.")
> + return queue
>
> def send_packet_pctype(self, mac, pkt_type="udp", frag=0, flags=None,
> tag=None, ethertype=None):
> """
> @@ -230,7 +231,7 @@ class TestQueue_region(TestCase):
> # 7 | 10 | 46 | Frag_IPv6
> # send the packets and verify the results
> queue_region = ["1"]
> - self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="udp")
> + queue_udp = self.send_and_check(queue_region, mac=self.pf_mac,
> + pkt_type="udp")
>
> # fortville can't parse the TCP SYN type packet, fortpark can parse it.
> if(self.nic in ["fortpark_TLV"]):
> @@ -245,10 +246,10 @@ class TestQueue_region(TestCase):
>
> # not assign ipv4-sctp packet to any queue region, the packet to
> queue region 0.
> queue_region = ["1"]
> - self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="sctp", tag=1)
> + queue_sctp = self.send_and_check(queue_region,
> mac=self.pf_mac,
> + pkt_type="sctp", tag=1)
>
> queue_region = ["11", "12", "13", "14"]
> - self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="ipv4")
> + queue_ipv4 = self.send_and_check(queue_region, mac=self.pf_mac,
> + pkt_type="ipv4")
>
> queue_region = ["5"]
> self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="ipv4", frag=1) @@ -258,10 +259,10 @@ class
> TestQueue_region(TestCase):
> # not assign ipv4-tcp SYN packet to any queue region, the packet to
> queue region 0.
> if(self.nic in ["fortpark_TLV"]):
> queue_region = ["1"]
> - self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="ipv6_tcp")
> + queue_ipv6tcp = self.send_and_check(queue_region,
> + mac=self.pf_mac, pkt_type="ipv6_tcp")
> else:
> queue_region = ["8", "9"]
> - self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="ipv6_tcp")
> + queue_ipv6tcp = self.send_and_check(queue_region,
> + mac=self.pf_mac, pkt_type="ipv6_tcp")
>
> queue_region = ["11", "12", "13", "14"]
> self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="ipv6_sctp", tag=2) @@ -287,19 +288,19 @@ class
> TestQueue_region(TestCase):
> out = self.dut.send_expect("show port 0 queue-region", "testpmd>
> ")
> self.get_and_compare_rules(out, 0, 0, 0)
>
> - # confirm packet not to the same queue after flush all the queue
> region rull.
> + # confirm packet not to the same queue after flush all the queue
> regions rull.
> self.send_packet_pctype(mac=self.pf_mac, pkt_type="udp")
> queue = self.get_queue_number()
> - self.verify(queue not in ["1"], "the queue regions have not been
> flushed clearly.")
> + self.verify(queue != queue_udp, "the queue regions have not
> + been flushed clearly.")
> self.send_packet_pctype(mac=self.pf_mac, pkt_type="sctp")
> queue = self.get_queue_number()
> - self.verify(queue not in ["1"], "the queue regions have not been
> flushed clearly.")
> + self.verify(queue != queue_sctp, "the queue regions have not
> + been flushed clearly.")
> self.send_packet_pctype(mac=self.pf_mac, pkt_type="ipv4")
> queue = self.get_queue_number()
> - self.verify(queue not in ["10", "11", "12", "13"], "the queue regions
> have not been flushed clearly.")
> + self.verify(queue != queue_ipv4, "the queue regions have not
> + been flushed clearly.")
> self.send_packet_pctype(mac=self.pf_mac, pkt_type="ipv6_tcp")
> queue = self.get_queue_number()
> - self.verify(queue not in ["8", "9"], "the queue regions have not been
> flushed clearly.")
> + self.verify(queue != queue_ipv6tcp, "the queue regions have not
> + been flushed clearly.")
>
> def test_up_map_queue_region(self):
> # set queue region on a port
> @@ -330,13 +331,13 @@ class TestQueue_region(TestCase):
> self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="ipv6_udp", prio=1)
>
> queue_region = ["10", "11", "12", "13"]
> - self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="tcp", prio=2)
> + queue_tcp = self.send_and_check(queue_region, mac=self.pf_mac,
> + pkt_type="tcp", prio=2)
>
> queue_region = ["10", "11", "12", "13"]
> self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="tcp", prio=7)
>
> queue_region = ["10", "11", "12", "13"]
> - self.send_and_check(queue_region, mac=self.pf_mac,
> pkt_type="udp", prio=7)
> + queue_udp = self.send_and_check(queue_region, mac=self.pf_mac,
> + pkt_type="udp", prio=7)
>
> self.send_packet_pctype(mac=self.pf_mac, pkt_type="udp")
> queue = self.get_queue_number() @@ -352,10 +353,10 @@ class
> TestQueue_region(TestCase):
> # confirm packet not to the same queue after flush all the queue
> region rull.
> self.send_packet_up(mac=self.pf_mac, pkt_type="udp", prio=7)
> queue = self.get_queue_number()
> - self.verify(queue not in ["10", "11", "12", "13"], "the queue regions
> have not been flushed clearly.")
> + self.verify(queue != queue_udp, "the queue regions have not
> + been flushed clearly.")
> self.send_packet_up(mac=self.pf_mac, pkt_type="tcp", prio=2)
> queue = self.get_queue_number()
> - self.verify(queue not in ["10", "11", "12", "13"], "the queue regions
> have not been flushed clearly.")
> + self.verify(queue != queue_tcp, "the queue regions have not
> + been flushed clearly.")
>
> def test_boundary_values(self):
> # boundary value testing of "Set a queue region on a port"
> --
> 2.5.0
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-12-29 7:57 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-28 10:10 [dts] [PATCH] tests: change checking method for queue-region rule Peng Yuan
2018-12-29 16:24 ` Lijuan Tu
2018-12-28 11:28 Peng Yuan
2018-12-29 1:35 ` Zhu, ShuaiX
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).