From patchwork Fri Oct 23 08:14:11 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yufen.Mo" X-Patchwork-Id: 81906 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id C398DA04DE; Fri, 23 Oct 2020 10:19:06 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id BB7C1A8F2; Fri, 23 Oct 2020 10:19:05 +0200 (CEST) Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by dpdk.org (Postfix) with ESMTP id AAD4CA8EB for ; Fri, 23 Oct 2020 10:19:02 +0200 (CEST) IronPort-SDR: tuSM1S6bKPkkuzIMS7AuoSLyFX0gKpax4kxpbbj/tos2RnjN2On0EAy2SSneWitYd0sHQ523Ge Hby4FfjAX8Zw== X-IronPort-AV: E=McAfee;i="6000,8403,9782"; a="146936535" X-IronPort-AV: E=Sophos;i="5.77,407,1596524400"; d="scan'208";a="146936535" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Oct 2020 01:18:51 -0700 IronPort-SDR: z2Px5tdVI8cbLoeDMu59FD3oXCG6sQ0u5nOYj6e49nmn5/SYLeT8lT0lAlMBN40SaTTneh/xHB ZeBTDoH3Gz4A== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.77,407,1596524400"; d="scan'208";a="534310587" Received: from dpdk-moyufen06.sh.intel.com ([10.67.116.208]) by orsmga005.jf.intel.com with ESMTP; 23 Oct 2020 01:18:50 -0700 From: yufengmx To: dts@dpdk.org, lijuan.tu@intel.com, lihongx.ma@intel.com Cc: yufengmx Date: Fri, 23 Oct 2020 16:14:11 +0800 Message-Id: <20201023081411.33229-4-yufengx.mo@intel.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20201023081411.33229-1-yufengx.mo@intel.com> References: <20201023081411.33229-1-yufengx.mo@intel.com> MIME-Version: 1.0 Subject: [dts] [PATCH V4 3/3] framework: check the python version 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" check the python version of tester. If the version is python2, print a warning message. Signed-off-by: yufengmx --- framework/tester.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/framework/tester.py b/framework/tester.py index ca179b2..482b0e4 100644 --- a/framework/tester.py +++ b/framework/tester.py @@ -43,7 +43,8 @@ from crb import Crb from net_device import GetNicObj from etgen import IxiaPacketGenerator, SoftwarePacketGenerator import random -from utils import GREEN, convert_int2ip, convert_ip2int +from utils import (GREEN, convert_int2ip, convert_ip2int, + check_crb_python_version) from exception import ParameterInvalidException from multiprocessing import Process from pktgen import getPacketGenerator @@ -66,6 +67,8 @@ class Tester(Crb): self.NAME = 'tester' self.scapy_session = None super(Tester, self).__init__(crb, serializer, self.NAME) + # check the python version of tester + check_crb_python_version(self) self.bgProcIsRunning = False self.duts = None