From f807490d000ae7db8bc8ef33ddda4cf867deb344 Mon Sep 17 00:00:00 2001 From: Shailesh Jagannath Padave Date: Tue, 19 Nov 2024 19:40:35 +0530 Subject: [PATCH] fixed tests --- .../java/com/netflix/conductor/common/tasks/TaskDefTest.java | 2 ++ .../test/java/com/netflix/conductor/common/tasks/TaskTest.java | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/common/src/test/java/com/netflix/conductor/common/tasks/TaskDefTest.java b/common/src/test/java/com/netflix/conductor/common/tasks/TaskDefTest.java index fe861c35b..5ea169689 100644 --- a/common/src/test/java/com/netflix/conductor/common/tasks/TaskDefTest.java +++ b/common/src/test/java/com/netflix/conductor/common/tasks/TaskDefTest.java @@ -82,6 +82,7 @@ public void testTaskDefInvalidEmail() { taskDef.setName("test-task"); taskDef.setRetryCount(1); taskDef.setTimeoutSeconds(1000); + taskDef.setTotalTimeoutSeconds(2000); taskDef.setResponseTimeoutSeconds(1); Set> result = validator.validate(taskDef); @@ -102,6 +103,7 @@ public void testTaskDefValidEmail() { taskDef.setRetryCount(1); taskDef.setTimeoutSeconds(1000); taskDef.setResponseTimeoutSeconds(1); + taskDef.setTotalTimeoutSeconds(2000); taskDef.setOwnerEmail("owner@test.com"); Set> result = validator.validate(taskDef); diff --git a/common/src/test/java/com/netflix/conductor/common/tasks/TaskTest.java b/common/src/test/java/com/netflix/conductor/common/tasks/TaskTest.java index 402fcfcb0..25f8276c0 100644 --- a/common/src/test/java/com/netflix/conductor/common/tasks/TaskTest.java +++ b/common/src/test/java/com/netflix/conductor/common/tasks/TaskTest.java @@ -98,7 +98,7 @@ public void testDeepCopyTask() { final Task task = new Task(); // In order to avoid forgetting putting inside the copy method the newly added fields check // the number of declared fields. - final int expectedTaskFieldsNumber = 41; + final int expectedTaskFieldsNumber = 42; final int declaredFieldsNumber = task.getClass().getDeclaredFields().length; assertEquals(expectedTaskFieldsNumber, declaredFieldsNumber); @@ -133,6 +133,7 @@ public void testDeepCopyTask() { task.setIsolationGroupId("groupId"); task.setStartTime(12L); task.setEndTime(20L); + task.setFirstStartTime(12L); task.setScheduledTime(7L); task.setRetried(false); task.setReasonForIncompletion("");