From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id DD93A2952 for ; Thu, 7 Jul 2016 08:10:03 +0200 (CEST) Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga102.fm.intel.com with ESMTP; 06 Jul 2016 23:10:04 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.28,323,1464678000"; d="scan'208";a="135129594" Received: from shvmail01.sh.intel.com ([10.239.29.42]) by fmsmga004.fm.intel.com with ESMTP; 06 Jul 2016 23:10:03 -0700 Received: from shecgisg003.sh.intel.com (shecgisg003.sh.intel.com [10.239.29.90]) by shvmail01.sh.intel.com with ESMTP id u676A0v5008641; Thu, 7 Jul 2016 14:10:00 +0800 Received: from shecgisg003.sh.intel.com (localhost [127.0.0.1]) by shecgisg003.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP id u6769wKx031417; Thu, 7 Jul 2016 14:10:00 +0800 Received: (from yliu84x@localhost) by shecgisg003.sh.intel.com (8.13.6/8.13.6/Submit) id u6769v30031413; Thu, 7 Jul 2016 14:09:57 +0800 From: Marvin Liu To: dts@dpdk.org Cc: Marvin Liu Date: Thu, 7 Jul 2016 14:09:57 +0800 Message-Id: <1467871797-31381-1-git-send-email-yong.liu@intel.com> X-Mailer: git-send-email 1.7.4.1 Subject: [dts] [PATCH] tests: fix dot1q layer not found 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: Thu, 07 Jul 2016 06:10:04 -0000 Packet module changed layer name from "dot1q" to "vlan", testsuites which handle packet by this module should be changed correspondingly. Signed-off-by: Marvin Liu diff --git a/tests/TestSuite_userspace_ethtool.py b/tests/TestSuite_userspace_ethtool.py index c23f841..c718a58 100644 --- a/tests/TestSuite_userspace_ethtool.py +++ b/tests/TestSuite_userspace_ethtool.py @@ -340,7 +340,7 @@ class TestUserspaceEthtool(TestCase, IxiaPacketGenerator): # send correct vlan packet to port pkt = Packet(pkt_type='VLAN_UDP') - pkt.config_layer('dot1q', {'vlan': vlan}) + pkt.config_layer('vlan', {'vlan': vlan}) tester_port = self.tester.get_local_port(port) intf = self.tester.get_interface(tester_port) pkt.send_pkt(tx_port=intf) @@ -350,7 +350,7 @@ class TestUserspaceEthtool(TestCase, IxiaPacketGenerator): # send incorrect vlan packet to port wrong_vlan = (vlan + 1) % 4096 - pkt.config_layer('dot1q', {'vlan': wrong_vlan}) + pkt.config_layer('vlan', {'vlan': wrong_vlan}) pkt.send_pkt(tx_port=intf) time.sleep(2) rx_pkts_wrong, _ = self.strip_portstats(port) @@ -359,7 +359,7 @@ class TestUserspaceEthtool(TestCase, IxiaPacketGenerator): # remove vlan self.dut.send_expect("vlan %d del %d" % (index, vlan), "EthApp>") # send same packet and make sure not received - pkt.config_layer('dot1q', {'vlan': vlan}) + pkt.config_layer('vlan', {'vlan': vlan}) pkt.send_pkt(tx_port=intf) time.sleep(2) rx_pkts_del, _ = self.strip_portstats(port) diff --git a/tests/TestSuite_vlan.py b/tests/TestSuite_vlan.py index bf20455..70a9813 100644 --- a/tests/TestSuite_vlan.py +++ b/tests/TestSuite_vlan.py @@ -90,7 +90,7 @@ class TestVlan(TestCase): pkts = load_sniff_packets(self.inst) vlans = [] for packet in pkts: - vlan = packet.strip_element_dot1q("vlan") + vlan = packet.strip_element_vlan("vlan") vlans.append(vlan) return vlans @@ -117,7 +117,7 @@ class TestVlan(TestCase): else: pkt = Packet(pkt_type='VLAN_UDP') pkt.config_layer('ether', {'dst': self.dmac, 'src': self.smac}) - pkt.config_layer('dot1q', {'vlan': vid}) + pkt.config_layer('vlan', {'vlan': vid}) pkt.send_pkt(tx_port=self.txItf) -- 1.9.3