Code Review
/
vpp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
VPP-1506: dump local punts and registered punt sockets
[vpp.git]
/
test
/
framework.py
diff --git
a/test/framework.py
b/test/framework.py
index
54b7a2d
..
8a1bfcb
100644
(file)
--- a/
test/framework.py
+++ b/
test/framework.py
@@
-12,6
+12,7
@@
import faulthandler
import random
import copy
import psutil
import random
import copy
import psutil
+import platform
from collections import deque
from threading import Thread, Event
from inspect import getdoc, isclass
from collections import deque
from threading import Thread, Event
from inspect import getdoc, isclass
@@
-133,6
+134,14
@@
def pump_output(testclass):
# of properly terminating the loop
# of properly terminating the loop
+def is_skip_aarch64_set():
+ return os.getenv('SKIP_AARCH64', 'n').lower() in ('yes', 'y', '1')
+
+
+def is_platform_aarch64():
+ return platform.machine() == 'aarch64'
+
+
def running_extended_tests():
s = os.getenv("EXTENDED_TESTS", "n")
return True if s.lower() in ("y", "yes", "1") else False
def running_extended_tests():
s = os.getenv("EXTENDED_TESTS", "n")
return True if s.lower() in ("y", "yes", "1") else False
@@
-184,6
+193,8
@@
class VppTestCase(unittest.TestCase):
classes. It provides methods to create and run test case.
"""
classes. It provides methods to create and run test case.
"""
+ extra_vpp_punt_config = []
+
@property
def packet_infos(self):
"""List of packet infos"""
@property
def packet_infos(self):
"""List of packet infos"""
@@
-265,8
+276,8
@@
class VppTestCase(unittest.TestCase):
c = os.getenv("CACHE_OUTPUT", "1")
cls.cache_vpp_output = False if c.lower() in ("n", "no", "0") else True
cls.set_debug_flags(d)
c = os.getenv("CACHE_OUTPUT", "1")
cls.cache_vpp_output = False if c.lower() in ("n", "no", "0") else True
cls.set_debug_flags(d)
- cls.vpp_bin = os.getenv('VPP_
TEST_
BIN', "vpp")
- cls.plugin_path = os.getenv('VPP_
TEST_
PLUGIN_PATH')
+ cls.vpp_bin = os.getenv('VPP_BIN', "vpp")
+ cls.plugin_path = os.getenv('VPP_PLUGIN_PATH')
cls.extern_plugin_path = os.getenv('EXTERN_PLUGINS')
plugin_path = None
if cls.plugin_path is not None:
cls.extern_plugin_path = os.getenv('EXTERN_PLUGINS')
plugin_path = None
if cls.plugin_path is not None:
@@
-299,6
+310,8
@@
class VppTestCase(unittest.TestCase):
"{", "plugin", "dpdk_plugin.so", "{", "disable",
"}", "plugin", "unittest_plugin.so", "{", "enable",
"}", "}", ]
"{", "plugin", "dpdk_plugin.so", "{", "disable",
"}", "plugin", "unittest_plugin.so", "{", "enable",
"}", "}", ]
+ if cls.extra_vpp_punt_config is not None:
+ cls.vpp_cmdline.extend(cls.extra_vpp_punt_config)
if plugin_path is not None:
cls.vpp_cmdline.extend(["plugin_path", plugin_path])
cls.logger.info("vpp_cmdline args: %s" % cls.vpp_cmdline)
if plugin_path is not None:
cls.vpp_cmdline.extend(["plugin_path", plugin_path])
cls.logger.info("vpp_cmdline args: %s" % cls.vpp_cmdline)
@@
-1073,7
+1086,7
@@
class VppTestResult(unittest.TestResult):
def symlink_failed(self):
if self.current_test_case_info:
try:
def symlink_failed(self):
if self.current_test_case_info:
try:
- failed_dir = os.getenv('
VPP_TEST_
FAILED_DIR')
+ failed_dir = os.getenv('FAILED_DIR')
link_path = os.path.join(
failed_dir,
'%s-FAILED' %
link_path = os.path.join(
failed_dir,
'%s-FAILED' %