aryangupta1998 commented on code in PR #8539: URL: https://github.com/apache/ozone/pull/8539#discussion_r2120851402
########## hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/ozone/freon/TestRandomKeyGenerator.java: ########## @@ -185,4 +187,24 @@ void cleanObjectsTest() { assertEquals(2, randomKeyGenerator.getNumberOfVolumesCleaned()); assertEquals(6, randomKeyGenerator.getNumberOfBucketsCleaned()); } + + @Test + void testBucketLayoutOption() { + RandomKeyGenerator randomKeyGenerator = + new RandomKeyGenerator(cluster().getConf()); + CommandLine cmd = new CommandLine(randomKeyGenerator); + cmd.execute("--num-of-volumes", "1", + "--num-of-buckets", "1", + "--num-of-keys", "2", + "--bucket-layout", "OBJECT_STORE" + ); + + assertEquals(1, randomKeyGenerator.getNumberOfVolumesCreated()); + assertEquals(1, randomKeyGenerator.getNumberOfBucketsCreated()); + assertEquals(2, randomKeyGenerator.getNumberOfKeysAdded()); + + // Fetch the bucket and check its layout + OzoneBucket bucket = randomKeyGenerator.getBucketForTesting(0); Review Comment: Can we also verify that the "buckets" map size is 1, which testifies that the bucket in the map is the same bucket generated by our test? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@ozone.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@ozone.apache.org For additional commands, e-mail: issues-h...@ozone.apache.org