forked from bblanchon/ArduinoJson
Parse empty object
This commit is contained in:
1 parent
0daf82eee2
commit
9c1b6b80aa
8 files changed
+64
-7
No files matched your search
@@ -0,0 +1,20 @@
|
||||
#include <gtest/gtest.h>
|
||||
#include <ArduinoJson/StaticJsonBuffer.hpp>
|
||||
|
||||
using namespace ArduinoJson;
|
||||
|
||||
class JsonParser_Object_Test : public testing::Test
|
||||
{
|
||||
protected:
|
||||
|
||||
|
||||
};
|
||||
|
||||
TEST_F(JsonParser_Object_Test, EmptyObject)
|
||||
{
|
||||
StaticJsonBuffer<10> jsonBuffer;
|
||||
char jsonString[] = "{}";
|
||||
JsonObject object = jsonBuffer.parseObject(jsonString);
|
||||
|
||||
EXPECT_TRUE(object.success());
|
||||
}
|
||||
Reference in new issue
Block a user