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 EC275A04A3; Mon, 4 Nov 2019 04:20:11 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id E55E7100C; Mon, 4 Nov 2019 04:20:11 +0100 (CET) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id 11CE6DE3 for ; Mon, 4 Nov 2019 04:20:10 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 03 Nov 2019 19:20:10 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.68,265,1569308400"; d="scan'208";a="205057138" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by orsmga006.jf.intel.com with ESMTP; 03 Nov 2019 19:20:10 -0800 Received: from fmsmsx157.amr.corp.intel.com (10.18.116.73) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.439.0; Sun, 3 Nov 2019 19:20:09 -0800 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by FMSMSX157.amr.corp.intel.com (10.18.116.73) with Microsoft SMTP Server (TLS) id 14.3.439.0; Sun, 3 Nov 2019 19:20:09 -0800 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.108]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.149]) with mapi id 14.03.0439.000; Mon, 4 Nov 2019 11:20:07 +0800 From: "Mo, YufengX" To: "Xiao, QimaiX" , "dts@dpdk.org" , "Tu, Lijuan" , "Xiao, QimaiX" Thread-Topic: [dts] [PATCH V2] tests/TestSuite_telemetry: update file_prefix in telemetry client Thread-Index: AQHVjXiKwjEcRP3EfEezXqYbCta/Vad6YCrAgAABy0A= Date: Mon, 4 Nov 2019 03:20:07 +0000 Message-ID: References: <1572300871-27885-1-git-send-email-qimaix.xiao@intel.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dts] [PATCH V2] tests/TestSuite_telemetry: update file_prefix in telemetry client 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" Hi, qimai Have you shared a document in dts community about how to use this new refac= tor pmdout module? If not, can you upload a document about it? Thanks. BRs Yufen, Mo > -----Original Message----- > From: Mo, YufengX > Sent: Monday, November 4, 2019 11:13 AM > To: 'Xiao Qimai' ; dts@dpdk.org; Tu, Lijuan > Cc: Xiao, QimaiX > Subject: RE: [dts] [PATCH V2] tests/TestSuite_telemetry: update file_pref= ix in telemetry client >=20 > Hi,qimai >=20 > You create a new session. But you haven't close it in suite tear_down_all= . >=20 > BRs > Yufen, Mo >=20 >=20 > > -----Original Message----- > > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of Xiao Qimai > > Sent: Tuesday, October 29, 2019 6:15 AM > > To: dts@dpdk.org > > Cc: Xiao, QimaiX > > Subject: [dts] [PATCH V2] tests/TestSuite_telemetry: update file_prefix= in telemetry client > > > > update file_prefix in telemetry client after testpmd launched > > > > Signed-off-by: Xiao Qimai > > --- > > tests/TestSuite_telemetry.py | 19 +++++++++++++++++++ > > 1 file changed, 19 insertions(+) > > > > diff --git a/tests/TestSuite_telemetry.py b/tests/TestSuite_telemetry.p= y > > index bb2c9e6..c6e7e08 100644 > > --- a/tests/TestSuite_telemetry.py > > +++ b/tests/TestSuite_telemetry.py > > @@ -250,6 +250,8 @@ class TestTelemetry(TestCase): > > socket=3Dsocket) > > self.testpmd_status =3D 'running' > > self.testpmd.execute_cmd('start') > > + if not self.change_flag: > > + self.change_run_fileprefix(output) > > return output > > > > def close_telemetry_server(self): > > @@ -441,6 +443,22 @@ class TestTelemetry(TestCase): > > # > > # test content > > # > > + def get_file_prefix(self, out): > > + m =3D re.search('socket /var/run/dpdk/(.+?)/', out) > > + if m: > > + self.file_prefix =3D m.group(1) if m.group(1) !=3D "rte" e= lse None > > + > > + def change_run_fileprefix(self, out): > > + self.get_file_prefix(out) > > + if self.file_prefix: > > + self.dut_session2 =3D self.dut.new_session() > > + cmd1 =3D "sed -i > > > 's/self.socket.send_fd.connect(\"\/var\/run\/dpdk\/.*\/telemetry\")/self.= socket.send_fd.connect(\"\/var\/run\/dpdk\/{0}\/telemetry\")/g' > > {1}".format( > > + self.file_prefix, os.path.join(self.target_dir, 'usert= ools/dpdk-telemetry-client.py')) > > + cmd =3D "sed -i > > > 's/self.socket.send_fd.connect(\"\/var\/run\/dpdk\/.*\/telemetry\")/self.= socket.send_fd.connect(\"\/var\/run\/dpdk\/{0}\/telemetry\")/g' > > {1}".format( > > + self.file_prefix, os.path.join(self.target_dir, 'dpdk_= telemetry_client.py')) > > + self.dut_session2.send_expect(cmd1, "# ", 3) > > + self.dut_session2.send_expect(cmd, "# ", 3) > > + self.change_flag =3D True > > > > def verify_basic_script(self): > > ''' > > @@ -553,6 +571,7 @@ class TestTelemetry(TestCase): > > self.init_test_binary_files() > > self.nic_grp =3D self.get_ports_by_nic_type() > > self.used_ports =3D [] > > + self.change_flag =3D False > > > > def set_up(self): > > """ > > -- > > 1.8.3.1