src/test/java/com/stijndepestel/geminio/PersisterTest.java
/**
     * Test if an inputstream is converted to a JSONObject as it should be.
     */
Test if an inputstream is converted to a JSONObject as it should be.
Test if an inputstream is converted to a JSONObject as it should be .
@Test
    public void loadTest() {
        final String json = "{\"ping\":\"pong\"}";
        final ByteArrayInputStream inputStream = new ByteArrayInputStream(
                json.getBytes());
        final JSONObject jsonObject = new Persister(inputStream).load();
        Assert.assertEquals("JSON strings should be equal", json,
                jsonObject.toString());
    }
@ Test public void loadTest ( ) { final String json = "{\"ping\":\"pong\"}" ; final ByteArrayInputStream inputStream = new ByteArrayInputStream ( json . getBytes ( ) ) ; final JSONObject jsonObject = new Persister ( inputStream ) . load ( ) ; Assert . assertEquals ( "JSON strings should be equal" , json , jsonObject . toString ( ) ) ; }
Test if an inputstream is converted to a JSONObject as it should be.
Test if an inputstream is converted to a JSONObject as it should be .