FileJSONProvider implements JSONProvider { @Override public JSONObject get() throws JSONException { try { return fileToJSON(); } catch (IOException e) { throw new JSONException(e); } } FileJSONProvider(File file); @Override JSONObject get();  }
@Test(groups = "fast") public void testComment() throws Exception { BufferedReader reader = new BufferedReader( new InputStreamReader(new ByteArrayInputStream(jsonWithComments.getBytes()))); readerReference.set(reader); JSONObject jsonObject = jsonProvider.get(); Assert.assertEquals(jsonObject.getString("key"), "value"); Assert.assertTrue(jsonObject.has("nested")); }