From patchwork Thu Jun 16 07:14:48 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Jiale, SongX" X-Patchwork-Id: 112848 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 28915A00C3; Thu, 16 Jun 2022 09:14:56 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 214F042BCA; Thu, 16 Jun 2022 09:14:56 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by mails.dpdk.org (Postfix) with ESMTP id C93A64114F for ; Thu, 16 Jun 2022 09:14:53 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1655363694; x=1686899694; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=p9F15yanT7ZjBGq2FzIzAYtrtJ37YS55lT2PxZtQYxo=; b=HGAi8RyKRJC0+cYqigrAlZ0zb9vpWw7tY8uYXNHKpHCTSRpJ+aTfSdgr T8uYflYIYvZ6znCGGYnLaIRrUzs5uyfTvuGKS64JP4VbkqXCJQ0Sc7o7n wXZunBXhxZ621SKC4VR9Dt9dcX6Ekf0EFPoh8XRQqB4qm8SUHu7Yc7qwc tWY0l3fjnJWmpO0TBkvi1XpaSQTADO8/RLgeQde9Cp3dChadWCHlZ+PQD IenswwYVH6RvAWubYgygD71x+C7PPba1UAd8WCm6ZbG5LFW5wwSV5L75I 08zuziF2Fb2Zsgg2ctxqr5yeMvix7sB2eblF8fpZ/n8qaZontWV9jZJyU w==; X-IronPort-AV: E=McAfee;i="6400,9594,10379"; a="365539723" X-IronPort-AV: E=Sophos;i="5.91,304,1647327600"; d="scan'208";a="365539723" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Jun 2022 00:14:52 -0700 X-IronPort-AV: E=Sophos;i="5.91,304,1647327600"; d="scan'208";a="589520434" Received: from unknown (HELO daily-regression-131.intel.com) ([10.239.252.131]) by fmsmga007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Jun 2022 00:14:51 -0700 From: Jiale Song To: dts@dpdk.org Cc: Jiale Song Subject: [dts] [PATCH V1] tests/ip_pipeline: optimize scripts Date: Thu, 16 Jun 2022 15:14:48 +0800 Message-Id: <20220616071448.136874-1-songx.jiale@intel.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 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 optimize 2 issue: 1.the app should be closed after the case test, otherwise the execution of other cases will be affected. 2.sometimes the port link status changes slowly. need to ensure that the port link status is up before sending the package. Signed-off-by: Jiale Song --- tests/TestSuite_ip_pipeline.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/TestSuite_ip_pipeline.py b/tests/TestSuite_ip_pipeline.py index ab1637b5..be9c05b9 100644 --- a/tests/TestSuite_ip_pipeline.py +++ b/tests/TestSuite_ip_pipeline.py @@ -103,6 +103,8 @@ class TestIPPipeline(TestCase): self.tcpdump_start_sniff(rx_interface, filters) + # check that the link status of the port sending the packet is up + self.tester.is_interface_up(tx_interface) # Prepare the pkts to be sent self.tester.scapy_foreground() self.tester.scapy_append('pkt = rdpcap("%s")' % (pcap_file)) @@ -1036,7 +1038,8 @@ class TestIPPipeline(TestCase): """ Run after each test case. """ - pass + # close app + self.dut.send_expect("^C", "# ") def tear_down_all(self): """