summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/ext/vapi_c_test.c6
-rw-r--r--test/framework.py5
2 files changed, 9 insertions, 2 deletions
diff --git a/test/ext/vapi_c_test.c b/test/ext/vapi_c_test.c
index a91e4014761..b5075e96c10 100644
--- a/test/ext/vapi_c_test.c
+++ b/test/ext/vapi_c_test.c
@@ -892,7 +892,8 @@ START_TEST (test_api_strings)
ck_assert_int_eq (strlen (str), strlen (cstr));
vec_free (cstr);
- vstr = vl_api_from_api_to_new_vec (&dump->payload.name_filter);
+ vstr = vl_api_from_api_to_new_vec (0 /* not really an API message */ ,
+ &dump->payload.name_filter);
ck_assert_ptr_ne (vstr, NULL);
/* Assert nul terminator NOT present */
ck_assert_int_eq (vec_len (vstr), strlen (str));
@@ -915,7 +916,8 @@ START_TEST (test_api_strings)
ck_assert_int_eq (strlen (str), strlen (cstr));
vec_free (cstr);
- vstr = vl_api_from_api_to_new_vec (&dump->payload.name_filter);
+ vstr = vl_api_from_api_to_new_vec (0 /* not a real api msg */ ,
+ &dump->payload.name_filter);
ck_assert_ptr_ne (vstr, NULL);
/* Assert nul terminator NOT present */
ck_assert_int_eq (vec_len (vstr), strlen (str));
diff --git a/test/framework.py b/test/framework.py
index c73b46c491b..9eea8bb03a5 100644
--- a/test/framework.py
+++ b/test/framework.py
@@ -387,6 +387,10 @@ class VppTestCase(unittest.TestCase):
else:
default_variant = ""
+ api_fuzzing = os.getenv("API_FUZZ")
+ if api_fuzzing is None:
+ api_fuzzing = 'off'
+
cls.vpp_cmdline = [cls.vpp_bin, "unix",
"{", "nodaemon", debug_cli, "full-coredump",
coredump_size, "runtime-dir", cls.tempdir, "}",
@@ -398,6 +402,7 @@ class VppTestCase(unittest.TestCase):
"statseg", "{", "socket-name", cls.stats_sock, "}",
"socksvr", "{", "socket-name", cls.api_sock, "}",
"node { ", default_variant, "}",
+ "api-fuzz {", api_fuzzing, "}",
"plugins",
"{", "plugin", "dpdk_plugin.so", "{", "disable",
"}", "plugin", "rdma_plugin.so", "{", "disable",