From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id 422DF5921 for ; Fri, 27 Nov 2015 08:14:04 +0100 (CET) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga103.fm.intel.com with ESMTP; 26 Nov 2015 23:14:03 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,350,1444719600"; d="scan'208";a="829977893" Received: from unknown (HELO dpdk-fedora20.icx.intel.com) ([10.238.55.12]) by orsmga001.jf.intel.com with ESMTP; 26 Nov 2015 23:14:02 -0800 From: yongjie To: dts@dpdk.org Date: Fri, 27 Nov 2015 15:09:33 +0800 Message-Id: <1448608174-27198-1-git-send-email-yongjiex.gu@intel.com> X-Mailer: git-send-email 1.9.3 Cc: Gu yongjie Subject: [dts] [PATCH] change the verification of pktbytes in pmd cases 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: , X-List-Received-Date: Fri, 27 Nov 2015 07:14:04 -0000 From: Gu yongjie Change the verification of pktbytes,because DPDK removes the crc bytes from byte counter. Signed-off-by: Gu yongjie --- tests/TestSuite_pmd.py | 20 ++++++-------------- 1 files changed, 6 insertions(+), 14 deletions(-) diff --git a/tests/TestSuite_pmd.py b/tests/TestSuite_pmd.py index 29dec2b..bfd5e03 100644 --- a/tests/TestSuite_pmd.py +++ b/tests/TestSuite_pmd.py @@ -299,7 +299,7 @@ class TestPmd(TestCase,IxiaPacketGenerator): for rxfreet_value in self.rxfreet_values: - self.pmdout.start_testpmd("all", "--coremask=%s --portmask=%s --nb-cores=2 --enable-rx-cksum --disable-hw-vlan --disable-rss --crc-strip --rxd=1024 --txd=1024 --rxfreet=%d" % (core_mask, port_mask, rxfreet_value)) + self.pmdout.start_testpmd("all", "--coremask=%s --portmask=%s --nb-cores=2 --enable-rx-cksum --disable-hw-vlan --disable-rss --rxd=1024 --txd=1024 --rxfreet=%d" % (core_mask, port_mask, rxfreet_value)) self.dut.send_expect("set fwd csum", "testpmd> ") self.dut.send_expect("start", "testpmd> ") @@ -402,19 +402,11 @@ class TestPmd(TestCase,IxiaPacketGenerator): self.verify(p0tx_pkts == p1rx_pkts, "packet pass assert error, %d RX packets, %d TX packets" % (p1rx_pkts, p0tx_pkts)) - if checksum_test: - if self.nic in ["powerville", "springville", "kawela_4"]: - self.verify(p1rx_bytes == frame_size, - "packet pass assert error, expected %d RX bytes, actual %d" % (frame_size, p1rx_bytes)) - else: - self.verify(p1rx_bytes == frame_size - 4, - "packet pass assert error, expected %d RX bytes, actual %d" % (frame_size - 4, p1rx_bytes)) - else: - self.verify(p1rx_bytes == frame_size, - "packet pass assert error, expected %d RX bytes, actual %d" % (frame_size, p1rx_bytes)) - - self.verify(p0tx_bytes == frame_size, - "packet pass assert error, expected %d TX bytes, actual %d" % (frame_size, p0tx_bytes)) + self.verify(p1rx_bytes == frame_size - 4, + "packet pass assert error, expected %d RX bytes, actual %d" % (frame_size - 4, p1rx_bytes)) + + self.verify(p0tx_bytes == frame_size - 4, + "packet pass assert error, expected %d TX bytes, actual %d" % (frame_size - 4, p0tx_bytes)) return out -- 1.7.4.4