aboutsummaryrefslogtreecommitdiffstats
path: root/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/deployment/DeploymentTriggerTest.java
diff options
context:
space:
mode:
authorJon Marius Venstad <venstad@gmail.com>2018-11-01 21:03:15 +0100
committerJon Marius Venstad <venstad@gmail.com>2018-11-01 21:28:52 +0100
commitbf06c2bd3ca2fc5eb74107c3066e4970711fb60b (patch)
treeea7621068b91799ef61aa05326fdb1dcca232fcd /controller-server/src/test/java/com/yahoo/vespa/hosted/controller/deployment/DeploymentTriggerTest.java
parent17af68683da8b4df81bbc7c4e4018c616369dc4b (diff)
Use a public Duration instead of a private primitive for max pause
Diffstat (limited to 'controller-server/src/test/java/com/yahoo/vespa/hosted/controller/deployment/DeploymentTriggerTest.java')
-rw-r--r--controller-server/src/test/java/com/yahoo/vespa/hosted/controller/deployment/DeploymentTriggerTest.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/deployment/DeploymentTriggerTest.java b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/deployment/DeploymentTriggerTest.java
index a7668349f66..db58ef1830f 100644
--- a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/deployment/DeploymentTriggerTest.java
+++ b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/deployment/DeploymentTriggerTest.java
@@ -530,8 +530,8 @@ public class DeploymentTriggerTest {
Application app = tester.createAndDeploy("app", 3, "default");
tester.upgradeSystem(new Version("9.8.7"));
- tester.applications().deploymentTrigger().pauseJob(app.id(), productionUsWest1, tester.clock().millis() + 1000);
- tester.applications().deploymentTrigger().pauseJob(app.id(), productionUsEast3, tester.clock().millis() + 3000);
+ tester.applications().deploymentTrigger().pauseJob(app.id(), productionUsWest1, tester.clock().instant().plus(Duration.ofSeconds(1)));
+ tester.applications().deploymentTrigger().pauseJob(app.id(), productionUsEast3, tester.clock().instant().plus(Duration.ofSeconds(3)));
// us-west-1 does not trigger when paused.
tester.deployAndNotify(app, true, systemTest);
@@ -542,7 +542,7 @@ public class DeploymentTriggerTest {
tester.clock().advance(Duration.ofMillis(1500));
tester.readyJobTrigger().run();
tester.assertRunning(productionUsWest1, app.id());
- tester.applications().deploymentTrigger().pauseJob(app.id(), productionUsWest1, tester.clock().millis() + 1000);
+ tester.applications().deploymentTrigger().pauseJob(app.id(), productionUsWest1, tester.clock().instant().plus(Duration.ofSeconds(1)));
tester.deployAndNotify(app, false, productionUsWest1);
tester.assertNotRunning(productionUsWest1, app.id());
tester.clock().advance(Duration.ofMillis(1000));