mirror of
https://github.com/google/nomulus.git
synced 2025-06-28 23:33:36 +02:00
Convert RDAP tests from simple.json to Gson
------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=247237275
This commit is contained in:
parent
3b8a8892bb
commit
38e2175699
16 changed files with 305 additions and 425 deletions
|
@ -30,7 +30,6 @@ import google.registry.rdap.RdapSearchResults.IncompletenessWarningType;
|
|||
import google.registry.request.Action;
|
||||
import google.registry.request.auth.Auth;
|
||||
import java.util.Optional;
|
||||
import org.json.simple.JSONValue;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
|
@ -168,7 +167,7 @@ public class RdapActionBaseTest extends RdapActionBaseTestCase<RdapActionBaseTes
|
|||
action.run();
|
||||
String payload = response.getPayload();
|
||||
assertThat(payload).doesNotContain("\n");
|
||||
assertThat(JSONValue.parse(payload)).isEqualTo(loadJsonFile("rdapjson_toplevel.json"));
|
||||
assertThat(parseJsonObject(payload)).isEqualTo(loadJsonFile("rdapjson_toplevel.json"));
|
||||
}
|
||||
|
||||
@Test
|
||||
|
@ -179,6 +178,6 @@ public class RdapActionBaseTest extends RdapActionBaseTestCase<RdapActionBaseTes
|
|||
action.run();
|
||||
String payload = response.getPayload();
|
||||
assertThat(payload).contains("\n");
|
||||
assertThat(JSONValue.parse(payload)).isEqualTo(loadJsonFile("rdapjson_toplevel.json"));
|
||||
assertThat(parseJsonObject(payload)).isEqualTo(loadJsonFile("rdapjson_toplevel.json"));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue