aboutsummaryrefslogtreecommitdiffstats
path: root/test/framework.py
diff options
context:
space:
mode:
authorKlement Sekera <klement@graphiant.com>2022-02-18 10:30:51 +0000
committerNeale Ranns <neale@graphiant.com>2022-02-21 08:29:00 +0000
commit140af1559e603d319806d1e580a4dc1f5debfb07 (patch)
treef2e143ea6eeade563fc5b6a86674471a2749852f /test/framework.py
parentcaf4e754ea635b0ed028e9e8ecba29b32ff4a8a7 (diff)
tests: allow not removing vpp objects after test
Some tests might want to keep vpp config in between test functions. Add a flag to allow that. Type: improvement Signed-off-by: Klement Sekera <klement.sekera@gmail.com> Change-Id: I90243cd667dce922b43b381f3d52f4ac0f6bf3a7
Diffstat (limited to 'test/framework.py')
-rw-r--r--test/framework.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/test/framework.py b/test/framework.py
index 7d03eebef9a..73da515064a 100644
--- a/test/framework.py
+++ b/test/framework.py
@@ -284,6 +284,7 @@ class VppTestCase(CPUInterface, unittest.TestCase):
extra_vpp_plugin_config = []
logger = null_logger
vapi_response_timeout = 5
+ remove_configured_vpp_objects_on_tear_down = True
@property
def packet_infos(self):
@@ -758,7 +759,8 @@ class VppTestCase(CPUInterface, unittest.TestCase):
self.logger.info(self.vapi.ppcli("show bihash"))
self.logger.info("Logging testcase specific show commands.")
self.show_commands_at_teardown()
- self.registry.remove_vpp_config(self.logger)
+ if self.remove_configured_vpp_objects_on_tear_down:
+ self.registry.remove_vpp_config(self.logger)
# Save/Dump VPP api trace log
m = self._testMethodName
api_trace = "vpp_api_trace.%s.%d.log" % (m, self.vpp.pid)