JSONParser parser = new JSONParser();
parser.parseJSON("{\"test\" : 1}");
Assert.assertEquals(1, parser.getInt("test"));
parser = new JSONParser();
parser.parseJSON("{test : { internal : {level : 2}}}");
Assert.assertEquals(2, parser.getInt("test.internal.level"));
Assert.assertFalse("No cache should have been used", parser.isHitCache());
Assert.assertEquals(2, parser.getInt("test.internal.level"));
Assert.assertTrue("Cache should have been used this time!", parser.isHitCache());