Skip to content
This repository was archived by the owner on Feb 26, 2025. It is now read-only.

Commit 30c593c

Browse files
author
sbeimin
committed
Better mocking of bucket existence check
1 parent 21609e6 commit 30c593c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/test/java/com/upplication/s3fs/util/AmazonS3ClientMock.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -639,7 +639,7 @@ public String getIdentifier() {
639639
}
640640
}
641641
}catch (IOException e) {
642-
throw new RuntimeException(e);
642+
throw new AmazonS3Exception("Problem creating Acl", e);
643643
}
644644

645645
return res;
@@ -1451,6 +1451,6 @@ public AmazonS3Waiters waiters() {
14511451

14521452
@Override
14531453
public boolean doesBucketExistV2(String bucketName) throws SdkClientException, AmazonServiceException {
1454-
return !"newer-bucket".equals(bucketName);
1454+
return Files.exists(base.resolve(bucketName));
14551455
}
14561456
}

0 commit comments

Comments
 (0)