You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Added comprehensive test coverage for safe type casting:
Exception cases (should throw JSONException, not ClassCastException):
- Malformed XML causing type mismatch in toJSONArray()
- Type mismatch in toJSONObject()
Valid cases (should continue to work):
- Valid XML to JSONArray conversion
- Valid XML to JSONObject conversion
These tests verify the fix for issue #1034 where ClassCastException
was thrown when parse() returned unexpected types.
0 commit comments