From 4870fe1d771f9b5cc484dad957904117d9876566 Mon Sep 17 00:00:00 2001 From: Rajkumar Pennadam Ramamoorthy Date: Thu, 11 Mar 2021 11:12:02 +0530 Subject: [PATCH] [swss-common] Remove object type argument from json array() constructor call. Default value set to value_t::array in constructor. Issue: https://github.com/Azure/sonic-sairedis/issues/801 Signed-off-by: Rajkumar Pennadam Ramamoorthy --- tests/json_ut.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/json_ut.cpp b/tests/json_ut.cpp index a2374f759..741c265c4 100644 --- a/tests/json_ut.cpp +++ b/tests/json_ut.cpp @@ -75,3 +75,12 @@ TEST(JSON, test) } file.close(); } + +TEST(JSON, Array) +{ + json arr = json::array(); + json::array_t a; + json arr1(a); + EXPECT_TRUE(arr.is_array()); + EXPECT_TRUE(arr1.is_array()); +}