mirror of
https://github.com/google/nomulus.git
synced 2025-05-20 11:19:35 +02:00
Refactor out creation of server TRIDs so they can be tested
------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=152837185
This commit is contained in:
parent
af942774f4
commit
8653d2f204
29 changed files with 174 additions and 62 deletions
|
@ -22,6 +22,7 @@ import static org.mockito.Mockito.verify;
|
|||
import static org.mockito.Mockito.when;
|
||||
|
||||
import com.google.common.collect.ImmutableMap;
|
||||
import google.registry.flows.EppTestComponent.FakeServerTridProvider;
|
||||
import google.registry.model.eppcommon.Trid;
|
||||
import google.registry.model.eppoutput.EppOutput;
|
||||
import google.registry.model.eppoutput.EppResponse;
|
||||
|
@ -86,12 +87,14 @@ public class EppControllerTest extends ShardableTestCase {
|
|||
eppController.bigQueryMetricsEnqueuer = metricsEnqueuer;
|
||||
eppController.flowComponentBuilder = flowComponentBuilder;
|
||||
eppController.eppMetrics = eppMetrics;
|
||||
eppController.serverTridProvider = new FakeServerTridProvider();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testMarshallingUnknownError() throws Exception {
|
||||
marshal(
|
||||
EppController.getErrorResponse(Result.create(Code.COMMAND_FAILED), Trid.create(null)),
|
||||
EppController.getErrorResponse(
|
||||
Result.create(Code.COMMAND_FAILED), Trid.create(null, "server-trid")),
|
||||
ValidationMode.STRICT);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue