public void test_noQuotesParseFailure() {
Exception ex = null;
try {
// Verify a malformed JSON string (no quotes on attributes), fails parse in strict mode.
JSONObject jObject = new JSONObject("{foo:\"bar\", bool: true}", true);
assertTrue(jObject.getBoolean("bool") == true);
System.out.println("JSON compacted text (jObject):\n");
System.out.println(jObject.toString());
} catch (Exception ex1) {
ex = ex1;
}
assertTrue(ex instanceof JSONException);
}