Migrate to android-json

Migrate from `org.json:json` to the clean room Apache 2.0 licensed
version that was developed for Android.

Fixes gh-5929
This commit is contained in:
Phillip Webb
2017-01-04 21:18:08 -08:00
parent 4cb7d86aec
commit cc7c2ebb87
22 changed files with 389 additions and 259 deletions

View File

@@ -20,6 +20,7 @@ import java.io.IOException;
import java.nio.charset.Charset;
import java.util.List;
import org.hamcrest.CoreMatchers;
import org.json.JSONException;
import org.junit.Test;
@@ -45,7 +46,7 @@ public class JsonReaderTests extends AbstractConfigurationMetadataTests {
@Test
public void invalidMetadata() throws IOException {
this.thrown.expect(JSONException.class);
this.thrown.expectCause(CoreMatchers.<Throwable>instanceOf(JSONException.class));
readFor("invalid");
}