[dts] [PATCH] tests/ipfrag: add method name in error message

Tu, Lijuan lijuan.tu at intel.com
Tue Apr 23 22:34:14 CEST 2019


Applied, thanks

> -----Original Message-----
> From: dts [mailto:dts-bounces at dpdk.org] On Behalf Of Rami Rosen
> Sent: Monday, April 22, 2019 6:48 AM
> To: dts at dpdk.org
> Cc: Rami Rosen <ramirose at gmail.com>
> Subject: [dts] [PATCH] tests/ipfrag: add method name in error message
> 
> There is no way to know, when getting "failed on forward packet size"
> error, whether it is from functional_check_ipv4() or functional_check_ipv6().
> This patch adds the method name when in these two method so we will be
> able to track it.
> 
> Signed-off-by: Rami Rosen <ramirose at gmail.com>
> ---
>  tests/TestSuite_ipfrag.py | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/tests/TestSuite_ipfrag.py b/tests/TestSuite_ipfrag.py index
> 9f47a2c..38a27e9 100644
> --- a/tests/TestSuite_ipfrag.py
> +++ b/tests/TestSuite_ipfrag.py
> @@ -170,7 +170,7 @@ l3fwd_ipv4_route_array[] = {\\\n"
> 
>              # verify normal packet just by number, verify fragment packet by all
> elements
>              pkts = self.tester.load_tcpdump_sniff_packets(inst)
> -            self.verify(len(pkts) == expPkts, "Failed on forward packet size " +
> str(size))
> +            self.verify(len(pkts) == expPkts, "in
> + functional_check_ipv4(): failed on forward packet size " + str(size))
>              if flag == 'frag':
>                  idx = 1
>                  for pkt in pkts:
> @@ -220,7 +220,7 @@ l3fwd_ipv4_route_array[] = {\\\n"
> 
>              # verify normal packet just by number, verify fragment packet by all
> elements
>              pkts = self.tester.load_tcpdump_sniff_packets(inst)
> -            self.verify(len(pkts) == expPkts, "Failed on forward packet size " +
> str(size))
> +            self.verify(len(pkts) == expPkts, "In
> + functional_check_ipv6(): failed on forward packet size " + str(size))
>              if flag == 'frag':
>                  idx = 1
>                  for pkt in pkts:
> --
> 1.8.3.1



More information about the dts mailing list