mirror of
https://github.com/bblanchon/ArduinoJson.git
synced 2025-07-29 18:27:37 +02:00
Parse empty array
This commit is contained in:
15
tests/JsonArray_Parser_Tests.cpp
Normal file
15
tests/JsonArray_Parser_Tests.cpp
Normal file
@ -0,0 +1,15 @@
|
||||
#include <gtest/gtest.h>
|
||||
#include <StaticJsonBuffer.h>
|
||||
|
||||
class JsonArray_Parser_Tests : public testing::Test
|
||||
{
|
||||
protected:
|
||||
StaticJsonBuffer<42> json;
|
||||
};
|
||||
|
||||
TEST_F(JsonArray_Parser_Tests, EmptyArray)
|
||||
{
|
||||
JsonArray array = json.parseArray("[]");
|
||||
|
||||
EXPECT_EQ(0, array.size());
|
||||
}
|
Reference in New Issue
Block a user