Cleanup and made tests for JsonParser