From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id D5B9BA055F; Fri, 27 May 2022 07:53:13 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A646140E50; Fri, 27 May 2022 07:53:13 +0200 (CEST) Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by mails.dpdk.org (Postfix) with ESMTP id D2B5B40E25 for ; Fri, 27 May 2022 07:53:10 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1653630792; x=1685166792; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=lNXvTqil7mJVsypwPfa/SoWZlqtNxXxMHlB4SWS/hnw=; b=CwEXeuh0p2ZQnb77kSXtTBPRrdYnxlI9tgRY1vd2MKMyJyjXbhLY8als Ng7rTpTlCMovtXuBb87OjSfkpFJJBaXXUyYnNRXYVOvc+dS3tfqVOK9qQ KfCL/1wQEgjDJBHF61bHnpupUdDfZ8InITyJxM72FqRP5LuQa0R8oJTF8 qIU0yMoLr5UOPI8bKjbsw9Wy1l6PMaB5JKitpJCaUlf0uzpQoDliuSmcJ 2Nz1fPScaaMNWvM568vztvVjDsNFmanrMShIQ9W/pPOWWQaeoL4Y8Cyhd h+8hPfi42tuTP0WcxVU8u+ztFNziz9Z6hnufnRABcQa+SKvRgCSIJOQea A==; X-IronPort-AV: E=McAfee;i="6400,9594,10359"; a="256460421" X-IronPort-AV: E=Sophos;i="5.91,254,1647327600"; d="scan'208";a="256460421" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 May 2022 22:53:08 -0700 X-IronPort-AV: E=Sophos;i="5.91,254,1647327600"; d="scan'208";a="603668473" Received: from unknown (HELO daily-regression-131.intel.com) ([10.239.251.131]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 May 2022 22:53:07 -0700 From: Jiale Song To: dts@dpdk.org Cc: Jiale Song Subject: [dts] [PATCH V1] short_live: fix script Date: Fri, 27 May 2022 13:53:03 +0800 Message-Id: <20220527055304.179776-1-songx.jiale@intel.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 fix 2 issue: 1.make the core in the eal parameter consistent with the core configured by the config parameter. 2.the output format of '/usr/bin/time' of FreeBSD is different from that of conventional Linux. add the '-p' parameter to make it output in posix format. Signed-off-by: Jiale Song --- tests/TestSuite_short_live.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/tests/TestSuite_short_live.py b/tests/TestSuite_short_live.py index e50c99a3..2be73481 100644 --- a/tests/TestSuite_short_live.py +++ b/tests/TestSuite_short_live.py @@ -67,6 +67,7 @@ class TestShortLiveApp(TestCase): self.app_l2fwd_path = self.dut.apps_name["l2fwd"] self.app_l3fwd_path = self.dut.apps_name["l3fwd"] self.app_testpmd = self.dut.apps_name["test-pmd"] + self.core_config = '1S/2C/1T' self.eal_para = self.dut.create_eal_parameters def set_up(self): @@ -186,10 +187,10 @@ class TestShortLiveApp(TestCase): Using linux time to get start up time """ time = [] - regex = re.compile(".* (\d+:\d{2}\.\d{2}).*") + regex = re.compile(".*real (\d+\.\d{2}).*") eal_para = self.dut.create_eal_parameters(no_pci=True) out = self.dut.send_expect( - "echo quit | time ./%s %s -- -i" % (self.app_testpmd, eal_para), "# ", 120 + "echo quit | time -p ./%s %s -- -i" % (self.app_testpmd, eal_para), "# ", 120 ) time = regex.findall(out) @@ -249,12 +250,15 @@ class TestShortLiveApp(TestCase): def test_clean_up_with_signal_l3fwd(self): repeat_time = 5 self.compile_examples("l3fwd") + core_list = self.dut.get_core_list(self.core_config) + eal_parmas = self.eal_para(cores=core_list) + for i in range(repeat_time): # dpdk start print("clean_up_with_signal_l3fwd round %d" % (i + 1)) self.dut.send_expect( - "%s %s -- -p 0x3 --config='(0,0,1),(1,0,2)' &" - % (self.app_l3fwd_path, self.eal_para()), + "%s %s -- -p 0x3 --config='(0,0,%s),(1,0,%s)' &" + % (self.app_l3fwd_path, eal_parmas, core_list[0], core_list[1]), "L3FWD: entering main loop", 120, ) -- 2.17.1