String text = "{\"f0\":{},\"f1\":{},\"f2\":{},\"f3\":{},\"f4\":{}, " + //
"\"f5\":{},\"f6\":{},\"f7\":{},\"f8\":{},\"f9\":{}}";
public void test_read() throws Exception {
JSONReader reader = new JSONReader(new StringReader(text));
reader.startObject();
int count = 0;
while (reader.hasNext()) {
String key = (String) reader.readObject();
Object value = reader.readObject();
Assert.assertNotNull(key);
Assert.assertNotNull(value);
count++;
}
Assert.assertEquals(10, count);
reader.endObject();
reader.close();
}