}
+TEST(formatable, str3) {
+ JSONFormattable f;
+ get_jf("{ \"foo\": \"1234bar56\" }", &f);
+ ASSERT_EQ((string)f["foo"], "1234bar56");
+}
+
TEST(formatable, int) {
JSONFormattable f;
get_jf("{ \"foo\": 1 }", &f);
ASSERT_EQ((int)f["obj"]["c"], 30);
}
+TEST(formatable, set2) {
+ JSONFormattable f;
+ f.set("foo", "1234bar56");
+ ASSERT_EQ((string)f["foo"], "1234bar56");
+}
+
TEST(formatable, erase) {
JSONFormattable f, f2;