From 4afb6acd124447dc6dbfa87275fc585f1de389cb Mon Sep 17 00:00:00 2001 From: Koushik R Date: Tue, 4 Jan 2022 23:58:09 +0530 Subject: [PATCH] Using a consistent Duration.of everywhere --- .../java/com/flipkart/ranger/core/utils/RangerTestUtils.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ranger-core/src/test/java/com/flipkart/ranger/core/utils/RangerTestUtils.java b/ranger-core/src/test/java/com/flipkart/ranger/core/utils/RangerTestUtils.java index 3c30c006..53e3e122 100644 --- a/ranger-core/src/test/java/com/flipkart/ranger/core/utils/RangerTestUtils.java +++ b/ranger-core/src/test/java/com/flipkart/ranger/core/utils/RangerTestUtils.java @@ -57,7 +57,7 @@ public static Service getService(String namespace, String serviceName){ refreshed and other boolean flags throughout the code. */ public static void sleepUntil(int numSeconds) { - await().pollDelay(numSeconds, TimeUnit.SECONDS).until(() -> true); + await().pollDelay(Duration.ofSeconds(numSeconds)).until(() -> true); } /* @@ -65,7 +65,7 @@ public static void sleepUntil(int numSeconds) { keeping the start intervals in mind. */ public static void sleepUntil(int numSeconds, Callable conditionEvaluator) { - await().pollDelay(numSeconds, TimeUnit.SECONDS).until(conditionEvaluator); + await().pollDelay(Duration.ofSeconds(numSeconds)).until(conditionEvaluator); } /*