You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Make tests more stable by using JSONAssert equals (#6247)
`avroSchema.getSchemaInfo().getSchema()` in `src/test/java/org/apache/pulsar/client/impl/schema/AvroSchemaTest.java` returns a JSON object. `schemaJson` compares with hard-coded JSON String. However, the order of entries in `schemaJson` is not guaranteed so the json results can contain entries in any order.
This PR proposes to use JSONAssert and modify the corresponding json test assertions so that the test is more stable.
### Motivation
Using JSONAssert and modifying the corresponding json test assertions so that the test is more stable.
### Modifications
Adding `assertJSONEquals` method and replacing `assertEquals` with it in tests `testNotAllowNullSchema` and `testAllowNullSchema`.
(cherry picked from commit 7dd52b8)
0 commit comments