- fixed GH #362: Defect in Var::parseString when there is no space between value and newline

- fixed GH #314: JSON parsing bug
- added GH #313: MetaColumn additions for Data::ODBC and Data::SQLite
This commit is contained in:
Alex Fabijanic
2014-04-29 21:25:30 -05:00
parent f038ac4e63
commit 8a9e7792d9
9 changed files with 23 additions and 6 deletions

View File

@@ -2192,10 +2192,18 @@ void VarTest::testJSONDeserializeString()
assert (b.convert<std::string>() == "test");
Var c('c');
std::string tst2 = Var::toString(c);
Var b2 = Var::parse(tst2);
tst = Var::toString(c);
Var b2 = Var::parse(tst);
char cc = b2.convert<char>();
assert (cc == 'c');
tst = "{ \"a\" : 1, \"b\" : 2 \n}";
a = Var::parse(tst);
assert(a.toString() == "{ \"a\" : \"1\", \"b\" : \"2\" }");
tst = "{ \"a\" : 1, \"b\" : 2\n}";
a = Var::parse(tst);
assert(a.toString() == "{ \"a\" : \"1\", \"b\" : \"2\" }");
}