summaryrefslogtreecommitdiffstats
path: root/src/vat2/test
diff options
context:
space:
mode:
Diffstat (limited to 'src/vat2/test')
-rw-r--r--src/vat2/test/vat2_test.api4
-rw-r--r--src/vat2/test/vat2_test.c7
2 files changed, 11 insertions, 0 deletions
diff --git a/src/vat2/test/vat2_test.api b/src/vat2/test/vat2_test.api
index ff503f0d03a..58961475e30 100644
--- a/src/vat2/test/vat2_test.api
+++ b/src/vat2/test/vat2_test.api
@@ -77,3 +77,7 @@ autoreply define test_vla5 {
vl_api_test_vlatype3_t data;
};
+/* Addresses */
+autoreply define test_addresses {
+ vl_api_address_t a;
+};
diff --git a/src/vat2/test/vat2_test.c b/src/vat2/test/vat2_test.c
index 10cfee4be17..f28bb414d56 100644
--- a/src/vat2/test/vat2_test.c
+++ b/src/vat2/test/vat2_test.c
@@ -142,6 +142,11 @@ struct msgs msgs[] = {
.tojson = (tojson_fn_t) vl_api_test_vla5_t_tojson,
.fromjson = (fromjson_fn_t) vl_api_test_vla5_t_fromjson,
},
+ {
+ .name = "test_addresses",
+ .tojson = (tojson_fn_t) vl_api_test_addresses_t_tojson,
+ .fromjson = (fromjson_fn_t) vl_api_test_addresses_t_fromjson,
+ },
};
struct tests tests[] = {
@@ -163,6 +168,8 @@ struct tests tests[] = {
"[1,2,3,4,5] }}" },
{ .s = "{\"_msgname\": \"test_vla5\", \"data\": { \"count\": 5, \"vla\": "
"\"0xaabbccddee\" }}" },
+ { .s = "{\"_msgname\": \"test_addresses\", \"a\": \"1.2.3.4\" }" },
+ { .s = "{\"_msgname\": \"test_addresses\", \"a\": \"2001:db8::23\" }" },
};
int main (int argc, char **argv)