[dts] [PATCH V2 2/2] vxlan: snyc the vxlan_sample.
Lijuan Tu
lijuanx.a.tu at intel.com
Wed Jun 14 11:07:16 CEST 2017
Signed-off-by: Lijuan Tu <lijuanx.a.tu at intel.com>
---
tests/TestSuite_vxlan.py | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/tests/TestSuite_vxlan.py b/tests/TestSuite_vxlan.py
index 411ce22..7d34cdd 100644
--- a/tests/TestSuite_vxlan.py
+++ b/tests/TestSuite_vxlan.py
@@ -24,7 +24,7 @@ from scapy.config import conf
from scapy.route import *
from test_case import TestCase
-from settings import HEADER_SIZE
+from settings import HEADER_SIZE, FOLDERS
from etgen import IxiaPacketGenerator
#
@@ -236,6 +236,11 @@ class VxlanTestConfig(object):
"""
Send vxlan pcap file by iface
"""
+ # load vxlan module to scapy
+ cwd = os.getcwd()
+ dir_vxlan_module = cwd + r'/' + FOLDERS['Depends']
+ self.test_case.tester.scapy_append("sys.path.append('%s')" % dir_vxlan_module)
+ self.test_case.tester.scapy_append("from vxlan import Vxlan")
self.test_case.tester.scapy_append(
'pcap = rdpcap("%s")' % self.pcap_file)
self.test_case.tester.scapy_append(
--
1.9.3
More information about the dts
mailing list