mirror of
https://github.com/google/nomulus.git
synced 2025-05-21 19:59:34 +02:00
Switch to constructor injection in a few actions
------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=232552406
This commit is contained in:
parent
927e8bbd73
commit
29d3ad8052
5 changed files with 49 additions and 50 deletions
|
@ -41,20 +41,14 @@ import org.junit.runners.JUnit4;
|
|||
public class RefreshDnsActionTest {
|
||||
|
||||
@Rule
|
||||
public final AppEngineRule appEngine = AppEngineRule.builder()
|
||||
.withDatastore()
|
||||
.withTaskQueue()
|
||||
.build();
|
||||
public final AppEngineRule appEngine =
|
||||
AppEngineRule.builder().withDatastore().withTaskQueue().build();
|
||||
|
||||
private final DnsQueue dnsQueue = mock(DnsQueue.class);
|
||||
private final FakeClock clock = new FakeClock();
|
||||
|
||||
private void run(TargetType type, String name) {
|
||||
RefreshDnsAction action = new RefreshDnsAction();
|
||||
action.clock = clock;
|
||||
action.domainOrHostName = name;
|
||||
action.type = type;
|
||||
action.dnsQueue = dnsQueue;
|
||||
action.run();
|
||||
new RefreshDnsAction(name, type, clock, dnsQueue).run();
|
||||
}
|
||||
|
||||
@Before
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue