@Test
public void testJsonSerializationForDescOrder() throws JSONException {

    String expectedJson = "{\"my_field\":{\"order\":\"desc\"}}";
    Sort s = new Sort("my_field", Sorting.DESC);
    JsonObject actualJsonObject = s.toJsonObject();
    JSONAssert.assertEquals(expectedJson, new Gson().toJson(actualJsonObject), false);
}