mirror of
https://github.com/stleary/JSON-java.git
synced 2025-08-03 11:25:30 -04:00
fix: change from JSONAssert to checking the similarity of JSONObjects
This commit is contained in:
parent
228598ca84
commit
e4aa7f1308
@ -8,7 +8,6 @@ import static org.junit.Assert.*;
|
|||||||
|
|
||||||
import org.json.*;
|
import org.json.*;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
import org.skyscreamer.jsonassert.JSONAssert;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Tests for org.json.JSONML.java
|
* Tests for org.json.JSONML.java
|
||||||
@ -763,8 +762,7 @@ public class JSONMLTest {
|
|||||||
final String xml = JSONML.toString(originalObject);
|
final String xml = JSONML.toString(originalObject);
|
||||||
final JSONObject revertedObject = JSONML.toJSONObject(xml, false);
|
final JSONObject revertedObject = JSONML.toJSONObject(xml, false);
|
||||||
final String newJson = revertedObject.toString();
|
final String newJson = revertedObject.toString();
|
||||||
assertTrue("JSON Objects are not similar",originalObject.similar(revertedObject));
|
assertTrue("original JSON does not equal the new JSON", originalObject.similar(revertedObject));
|
||||||
JSONAssert.assertEquals("original JSON does not equal the new JSON", originalJson, newJson, false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// these tests do not pass for the following reasons:
|
// these tests do not pass for the following reasons:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user