Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
hendrikebbers committed Dec 3, 2024
2 parents 9f91a7f + 0d762a5 commit 9f1cc1f
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ void testNullParams() {
Assertions.assertThrows(NullPointerException.class, () -> fileClient.readFile((FileId) null));
Assertions.assertThrows(NullPointerException.class, () -> fileClient.deleteFile((String) null));
Assertions.assertThrows(NullPointerException.class, () -> fileClient.deleteFile((FileId) null));
Assertions.assertThrows(NullPointerException.class, () -> fileClient.getExpirationTime(null));
}

@Test
Expand Down Expand Up @@ -200,6 +201,14 @@ void testGetExpirationTime() throws Exception {
Assertions.assertTrue(expirationTime.isBefore(definedExpirationTime.plusSeconds(1)));
}

@Test
void testGetExpirationTimeForFailures() {
//given
final FileId invalidFileId = FileId.fromString("1.2.3");
//then
Assertions.assertThrows(HieroException.class, () -> fileClient.getExpirationTime(invalidFileId));
}

@Test
@Disabled("Always fails with AUTORENEW_DURATION_NOT_IN_RANGE. Needs to be investigated further.")
void testUpdateExpirationTime() throws Exception {
Expand Down

0 comments on commit 9f1cc1f

Please sign in to comment.