From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 58CE4A0566; Wed, 11 Mar 2020 07:20:17 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 0F7021BF7F; Wed, 11 Mar 2020 07:20:17 +0100 (CET) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by dpdk.org (Postfix) with ESMTP id 633572BAA for ; Wed, 11 Mar 2020 07:20:15 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Mar 2020 23:20:14 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,518,1574150400"; d="scan'208";a="261043067" Received: from unknown (HELO dpdk-xiaoqimai-dut.sh.intel.com) ([10.240.179.33]) by orsmga002.jf.intel.com with ESMTP; 10 Mar 2020 23:20:12 -0700 From: Xiao Qimai To: dts@dpdk.org Cc: Xiao Qimai Date: Wed, 11 Mar 2020 14:14:48 +0800 Message-Id: <1583907288-75854-1-git-send-email-qimaix.xiao@intel.com> X-Mailer: git-send-email 1.8.3.1 Subject: [dts] [PATCH V1]tests/TestSuite_pvp_vhost_user_reconnect: fix teardown to avoid interfere next case X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org Sender: "dts" *. fix failed case interferes other cases Signed-off-by: Xiao Qimai --- tests/TestSuite_pvp_vhost_user_reconnect.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/tests/TestSuite_pvp_vhost_user_reconnect.py b/tests/TestSuite_pvp_vhost_user_reconnect.py index f361373..96ce734 100644 --- a/tests/TestSuite_pvp_vhost_user_reconnect.py +++ b/tests/TestSuite_pvp_vhost_user_reconnect.py @@ -320,7 +320,6 @@ class TestPVPVhostUserReconnect(TestCase): self.vm_testpmd_start() self.send_and_verify(vm_cycle, "reconnet from VM") self.result_table_print() - self.stop_all_apps() def test_perf_split_ring_reconnet_two_vms(self): """ @@ -352,7 +351,6 @@ class TestPVPVhostUserReconnect(TestCase): self.vm_testpmd_start() self.send_and_verify(vm_cycle, "reconnet from VM") self.result_table_print() - self.stop_all_apps() def test_perf_split_ring_vm2vm_virtio_net_reconnet_two_vms(self): """ @@ -419,7 +417,6 @@ class TestPVPVhostUserReconnect(TestCase): self.vm_testpmd_start() self.send_and_verify(vm_cycle, "reconnet from VM") self.result_table_print() - self.stop_all_apps() def test_perf_packed_ring_reconnet_two_vms(self): """ @@ -451,7 +448,6 @@ class TestPVPVhostUserReconnect(TestCase): self.vm_testpmd_start() self.send_and_verify(vm_cycle, "reconnet from VM") self.result_table_print() - self.stop_all_apps() def test_perf_packed_ring_virtio_net_reconnet_two_vms(self): """ @@ -492,12 +488,18 @@ class TestPVPVhostUserReconnect(TestCase): # # Run after each test case. # - self.dut.send_expect("killall -s INT testpmd", "# ") - self.dut.send_expect("killall -s INT qemu-system-x86_64", "# ") + try: + self.stop_all_apps() + except Exception as e: + self.logger.warning(e) + finally: + self.dut.kill_all() + self.dut.send_expect("killall -s INT qemu-system-x86_64", "# ") time.sleep(2) def tear_down_all(self): """ Run after each test suite. """ + self.dut.kill_all() pass -- 1.8.3.1