This is an automated email from the ASF dual-hosted git repository.
gortiz pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git
The following commit(s) were added to refs/heads/master by this push:
new bcb58c8520 [bugfix] Loose S3PinotFSTest.testMoveFile() test
lastModified time check value (#13643)
bcb58c8520 is described below
commit bcb58c85208a46f0f643b6c2ac19dfb694035e79
Author: Xiang Fu <[email protected]>
AuthorDate: Wed Jul 17 07:33:34 2024 -0700
[bugfix] Loose S3PinotFSTest.testMoveFile() test lastModified time check
value (#13643)
---
.../test/java/org/apache/pinot/plugin/filesystem/S3PinotFSTest.java | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git
a/pinot-plugins/pinot-file-system/pinot-s3/src/test/java/org/apache/pinot/plugin/filesystem/S3PinotFSTest.java
b/pinot-plugins/pinot-file-system/pinot-s3/src/test/java/org/apache/pinot/plugin/filesystem/S3PinotFSTest.java
index 48224a359d..34edc0a644 100644
---
a/pinot-plugins/pinot-file-system/pinot-s3/src/test/java/org/apache/pinot/plugin/filesystem/S3PinotFSTest.java
+++
b/pinot-plugins/pinot-file-system/pinot-s3/src/test/java/org/apache/pinot/plugin/filesystem/S3PinotFSTest.java
@@ -460,8 +460,10 @@ public class S3PinotFSTest {
sourceHeadObjectResponse.eTag());
Assert.assertEquals(targetHeadObjectResponse.replicationStatusAsString(),
sourceHeadObjectResponse.replicationStatusAsString());
- Assert.assertEquals(targetHeadObjectResponse.lastModified(),
- sourceHeadObjectResponse.lastModified());
+ // Last modified time might not be exactly the same, hence we give 5
seconds buffer.
+ Assert.assertTrue(Math.abs(
+ targetHeadObjectResponse.lastModified().getEpochSecond() -
sourceHeadObjectResponse.lastModified()
+ .getEpochSecond()) < 5);
} finally {
FileUtils.deleteQuietly(file);
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]