[dts] [PATCH V1] add test suite vhost_pmd_xstats

Liu, Yong yong.liu at intel.com
Mon Feb 20 10:26:11 CET 2017


Gang, stability test will cause too much time for running. You can limit 
the duration to few minutes and let's merge this suite first.
Then we need one solution for distribute different kinds of cases. It'll 
be next step.

Thanks,
Marvin

On 02/20/2017 04:45 PM, xu,gang wrote:
> +
> +    def test_stability(self):
> +        """
> +        Verify stability case with multiple queues for Vhsot PMD xstats
> +        Send packets for 30 minutes, check the Xstatsa still can work correctly
> +        """
> +        self.scapy_num = 0
> +        self.prepare_start()
> +        date_old = datetime.datetime.now()
> +        date_new = date_old + datetime.timedelta(minutes=30)
> +        while(1):
> +            date_now = datetime.datetime.now()
> +            self.scapy_send_packet(64, self.dmac, 1)
> +            if date_now >= date_new:
> +                break
> +        out_0 = self.dut.send_expect(
> +            "show port xstats %s" % self.dut_ports[0], "testpmd>", 60)
> +        rx_packet = re.search("rx_size_64_packets:\s*(\d*)", out_0)
> +        rx_packets = rx_packet.group(1)
> +        self.verify(self.scapy_num == int(rx_packets), "Error for rx_package:%s != tx_package :%s" % (
> +            self.scapy_num, int(rx_packets)))



More information about the dts mailing list