[dts] [PATCH]tests vf_to_vf_nic_bridge:fix "killall tcpdump" won't get usefull infomation

Liu, Yong yong.liu at intel.com
Tue Jul 12 03:15:41 CEST 2016


Applied, fixed some typo in git commit.

On 07/11/2016 09:49 AM, Lijuan Tu wrote:
> we use "killall tcpdump" to get "x packets captured" infomation before.
> but on some os ,it is invalid.
>
> Signed-off-by: Lijuan Tu <lijuanx.a.tu at intel.com>
> ---
>   tests/TestSuite_vf_to_vf_nic_bridge.py | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/tests/TestSuite_vf_to_vf_nic_bridge.py b/tests/TestSuite_vf_to_vf_nic_bridge.py
> index 4137404..9c5548b 100644
> --- a/tests/TestSuite_vf_to_vf_nic_bridge.py
> +++ b/tests/TestSuite_vf_to_vf_nic_bridge.py
> @@ -187,7 +187,7 @@ class TestVF2VFBridge(TestCase):
>           self.vm0_dut.restore_interfaces()
>           self.vm0_ports = self.vm0_dut.get_ports('any')
>           vf0_intf = self.vm0_dut.ports_info[self.vm0_ports[0]]['intf']
> -        self.vm0_dut.send_expect('tcpdump -i %s -s 1000 > /dev/null &' % vf0_intf, '#', 30)
> +        self.vm0_dut.send_expect('tcpdump -i %s -s 1000 ' % vf0_intf, 'tcpdump', 30)
>   
>           self.vm1_ports = self.vm1_dut.get_ports('any')
>           self.prepare_pktgen(self.vm1_dut)
> @@ -204,7 +204,7 @@ class TestVF2VFBridge(TestCase):
>           self.send_stream_pktgen(self.vm1_dut)
>           self.stop_stream_pktgen(self.vm1_dut)
>   
> -        recv_tcpdump = self.vm0_dut.send_expect('killall tcpdump', '#', 30)
> +        recv_tcpdump = self.vm0_dut.send_expect('^C', '#', 30)
>           time.sleep(5)
>           recv_pattern = re.compile("(\d+) packets captured")
>           recv_info = recv_pattern.search(recv_tcpdump)



More information about the dts mailing list