Removed the automatic expansion of DynamicJsonDocument

This commit is contained in:
Benoit Blanchon
2018-11-16 10:26:59 +01:00
parent c832edbda3
commit 2bd280df80
28 changed files with 446 additions and 919 deletions

View File

@ -6,6 +6,18 @@
#include <catch.hpp>
TEST_CASE("StaticJsonDocument") {
SECTION("capacity()") {
SECTION("matches template argument") {
StaticJsonDocument<256> doc;
REQUIRE(doc.capacity() == 256);
}
SECTION("rounds up template argument") {
StaticJsonDocument<253> doc;
REQUIRE(doc.capacity() == 256);
}
}
SECTION("serializeJson()") {
StaticJsonDocument<200> doc;
JsonObject obj = doc.to<JsonObject>();