test suite reviews and discussions
 help / color / mirror / Atom feed
From: "Zhang, YanX A" <yanx.a.zhang@intel.com>
To: "dts@dpdk.org" <dts@dpdk.org>, "Lin, Xueqin" <xueqin.lin@intel.com>
Cc: "Lin, Xueqin" <xueqin.lin@intel.com>
Subject: Re: [dts] [PATCH] tests/vf_daemon: add show and clear statistics case
Date: Tue, 30 Apr 2019 01:46:24 +0000	[thread overview]
Message-ID: <2C49E4B25FAD1D419F7564D633EF72E1581F0B@shsmsx102.ccr.corp.intel.com> (raw)
In-Reply-To: <4DC48DF9BDA3E54A836D2D3C057DEC6F0B178938@SHSMSX101.ccr.corp.intel.com>

 tested-by:  Zhang, YanX A <yanx.a.zhang@intel.com>

> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of Xueqin Lin
> Sent: Monday, April 29, 2019 11:32 AM
> To: dts@dpdk.org
> Cc: Lin, Xueqin <xueqin.lin@intel.com>
> Subject: [dts] [PATCH] tests/vf_daemon: add show and clear statistics 
> case
> 
> Signed-off-by: Xueqin Lin <xueqin.lin@intel.com>
> 
> ---
>  tests/TestSuite_vf_daemon.py | 34 ++++++++++++++++++++++++++++++++++
>  1 file changed, 34 insertions(+)
> 
> diff --git a/tests/TestSuite_vf_daemon.py 
> b/tests/TestSuite_vf_daemon.py index 0dd797b..41955c8 100644
> --- a/tests/TestSuite_vf_daemon.py
> +++ b/tests/TestSuite_vf_daemon.py
> @@ -696,6 +696,40 @@ class TestVfDaemon(TestCase):
>          self.vm0_testpmd.execute_cmd('vlan set strip off 0')
>          self.vm0_testpmd.execute_cmd('vlan set filter off 0')
> 
> +    def test_stats_show_clear(self):
> +        """
> +        Show and clear statistics for a VF from PF
> +        """
> +        self.check_vf_link_status()
> +        self.vf0_mac = self.vm0_testpmd.get_port_mac(0)
> +        out = self.dut_testpmd.execute_cmd('show vf stats 0 0')
> +        self.verify("RX-packets: 0" in out and "TX-packets: 0" in out,
> +            "Fail to show VF RX and TX stats from PF")
> +        out = self.vm0_testpmd.execute_cmd('show port stats 0')
> +        self.verify("RX-packets: 0" in out and "TX-packets: 0" in out,
> +            "Fail to show VF RX and TX stats")
> +
> +        self.vm0_testpmd.execute_cmd('set fwd mac')
> +        self.vm0_testpmd.execute_cmd('set verbose 1')
> +        self.vm0_testpmd.execute_cmd('start')
> +
> +        self.send_packet(self.vf0_mac, 0, 64 , 10)
> +
> +        out = self.dut_testpmd.execute_cmd('show vf stats 0 0')
> +        self.verify("RX-packets: 10" in out and "TX-packets: 10" in out,
> +            "Wrong to show VF RX and TX packets from PF")
> +        out = self.vm0_testpmd.execute_cmd('show port stats 0')
> +        self.verify("RX-packets: 10" in out and "TX-packets: 10" in out,
> +            "Wrong to show VF RX and TX stats")
> +
> +        self.dut_testpmd.execute_cmd('clear vf stats 0 0')
> +        out = self.dut_testpmd.execute_cmd('show vf stats 0 0')
> +        self.verify("RX-packets: 0" in out and "TX-packets: 0" in out,
> +            "Fail to clear VF RX and TX stats from PF")
> +        out = self.vm0_testpmd.execute_cmd('show port stats 0')
> +        self.verify("RX-packets: 0" in out and "TX-packets: 0" in out,
> +            "Wrong to show VF RX and TX stats after clear")
> +
> 
>      def tear_down(self):
>          self.vm0_testpmd.quit()
> --
> 2.5.5


  parent reply	other threads:[~2019-04-30  1:46 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-29  3:31 Xueqin Lin
     [not found] ` <4DC48DF9BDA3E54A836D2D3C057DEC6F0B178938@SHSMSX101.ccr.corp.intel.com>
2019-04-30  1:46   ` Zhang, YanX A [this message]
2019-05-08  8:00 ` Li, WenjieX A
2019-05-13  2:03 ` Tu, Lijuan
2019-05-13  2:25   ` Lin, Xueqin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2C49E4B25FAD1D419F7564D633EF72E1581F0B@shsmsx102.ccr.corp.intel.com \
    --to=yanx.a.zhang@intel.com \
    --cc=dts@dpdk.org \
    --cc=xueqin.lin@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).