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 A11D7A0487 for ; Thu, 4 Jul 2019 18:48:00 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 300A531FC; Thu, 4 Jul 2019 18:48:00 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com [67.231.156.173]) by dpdk.org (Postfix) with ESMTP id 4A2632C52 for ; Thu, 4 Jul 2019 18:47:59 +0200 (CEST) Received: from pps.filterd (m0045851.ppops.net [127.0.0.1]) by mx0b-0016f401.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x64GiLWa004551; Thu, 4 Jul 2019 09:47:58 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : mime-version : content-type; s=pfpt0818; bh=YSOr7KvoFSaKdGzEXfh82wa5L49LIkWFM76Us9EtmN4=; b=Wj8IBNdqNrruOVN+ZzSB8/GwpftlcfKdyywGoO5ha24SzOItaO/JMvYccNP0PoFXtCWE gJWwvE0M23dceZLbnObxJ4L+12INu6XJa5yBMRJWX0ZLqctvcYSolqWMjyXQ6cA5uG9Y 4fo6ZK2KpiI5B+6C61Xi6VwIORrNUuu0Hy/uZqmRIEWzjLuhistY9KOBwCRnwk1hDexL QAgA805fx2BOyprDhOr/6mfxeAR+abrwXkey2OCp8MeVGGalAoU/XOa8jw9rXsgfCauA xcCBT5mfy6/aR2mWTbl/MPqC1PHqI6rwlvWNk98ZSSMnHKPlpBmVFujeer7bV7jJJWix OA== Received: from sc-exch01.marvell.com ([199.233.58.181]) by mx0b-0016f401.pphosted.com with ESMTP id 2thjyr8ffc-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Thu, 04 Jul 2019 09:47:58 -0700 Received: from SC-EXCH01.marvell.com (10.93.176.81) by SC-EXCH01.marvell.com (10.93.176.81) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Thu, 4 Jul 2019 09:47:56 -0700 Received: from maili.marvell.com (10.93.176.43) by SC-EXCH01.marvell.com (10.93.176.81) with Microsoft SMTP Server id 15.0.1367.3 via Frontend Transport; Thu, 4 Jul 2019 09:47:56 -0700 Received: from dut1171.mv.qlogic.com (unknown [10.112.88.18]) by maili.marvell.com (Postfix) with ESMTP id 40F183F703F; Thu, 4 Jul 2019 09:47:56 -0700 (PDT) Received: from dut1171.mv.qlogic.com (localhost [127.0.0.1]) by dut1171.mv.qlogic.com (8.14.7/8.14.7) with ESMTP id x64GlufX017555; Thu, 4 Jul 2019 09:47:56 -0700 Received: (from root@localhost) by dut1171.mv.qlogic.com (8.14.7/8.14.7/Submit) id x64Glt5H017554; Thu, 4 Jul 2019 09:47:55 -0700 From: Yash Sharma To: , , CC: , , , yash Date: Thu, 4 Jul 2019 09:47:53 -0700 Message-ID: <20190704164753.17518-1-ysharma@marvell.com> X-Mailer: git-send-email 2.12.0 MIME-Version: 1.0 Content-Type: text/plain X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-07-04_07:, , signatures=0 Subject: [dts] [PATCH 1/1] tests/TestSuite_mac_filter.py Correction in while loop condition. 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" From: yash Removing '=' from while loop condition as i is initialized to 0 and the loop iterates upto 256 resulting in total 257 iterations, as a result of that an extra unwanted invalid mac address is added at the end i.e. "00:01:00:00:00:100",it returns not expected String which doesn't match with the string in verify function, Leading to test failure. Signed-off-by: yash --- tests/TestSuite_mac_filter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/TestSuite_mac_filter.py b/tests/TestSuite_mac_filter.py index a28bf9a..7b5eb43 100644 --- a/tests/TestSuite_mac_filter.py +++ b/tests/TestSuite_mac_filter.py @@ -168,7 +168,7 @@ class TestMacFilter(TestCase): # add 1 address more that max number i = 0 base_addr = "00:01:00:00:00:" - while i <= int(self.max_mac_addr): + while i < int(self.max_mac_addr): new_addr = base_addr + "%0.2X" % i out = self.dut.send_expect("mac_addr add %d" % portid + " %s" % new_addr, "testpmd>") i = i + 1 -- 1.8.3.1