-
Notifications
You must be signed in to change notification settings - Fork 509
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "Adding total timeout to task models"
- Loading branch information
1 parent
fdf354f
commit 6115cbb
Showing
9 changed files
with
6 additions
and
85 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -74,28 +74,6 @@ public void testTaskDef() { | |
assertTrue(validationErrors.contains("ownerEmail cannot be empty")); | ||
} | ||
|
||
@Test | ||
public void testTaskDefTotalTimeOutSeconds() { | ||
TaskDef taskDef = new TaskDef(); | ||
taskDef.setName("test-task"); | ||
taskDef.setRetryCount(1); | ||
taskDef.setTimeoutSeconds(1000); | ||
taskDef.setTotalTimeoutSeconds(900); | ||
taskDef.setResponseTimeoutSeconds(1); | ||
taskDef.setOwnerEmail("[email protected]"); | ||
|
||
Set<ConstraintViolation<Object>> result = validator.validate(taskDef); | ||
assertEquals(1, result.size()); | ||
|
||
List<String> validationErrors = new ArrayList<>(); | ||
result.forEach(e -> validationErrors.add(e.getMessage())); | ||
|
||
assertTrue( | ||
validationErrors.toString(), | ||
validationErrors.contains( | ||
"TaskDef: test-task timeoutSeconds: 1000 must be less than or equal to totalTimeoutSeconds: 900")); | ||
} | ||
|
||
@Test | ||
public void testTaskDefInvalidEmail() { | ||
TaskDef taskDef = new TaskDef(); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters