From 3f29d7aa49c61327c8cb9157cecaf797cc7af405 Mon Sep 17 00:00:00 2001 From: Sagar Sumit Date: Tue, 27 Sep 2022 17:16:45 +0530 Subject: [PATCH] Fix test --- .../apache/hudi/table/functional/TestCleanPlanExecutor.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hudi-client/hudi-spark-client/src/test/java/org/apache/hudi/table/functional/TestCleanPlanExecutor.java b/hudi-client/hudi-spark-client/src/test/java/org/apache/hudi/table/functional/TestCleanPlanExecutor.java index 2f6228e87b85..783358848035 100644 --- a/hudi-client/hudi-spark-client/src/test/java/org/apache/hudi/table/functional/TestCleanPlanExecutor.java +++ b/hudi-client/hudi-spark-client/src/test/java/org/apache/hudi/table/functional/TestCleanPlanExecutor.java @@ -265,13 +265,13 @@ public void testKeepLatestCommits( } @ParameterizedTest - @ValueSource(Boolean.class) - public void testKeepLatestFileVersions(boolean ) throws Exception { + @ValueSource(booleans = {true, false}) + public void testKeepLatestFileVersions(boolean incrementalCleaningEnabled) throws Exception { HoodieWriteConfig config = HoodieWriteConfig.newBuilder().withPath(basePath) .withMetadataConfig(HoodieMetadataConfig.newBuilder().withAssumeDatePartitioning(true).build()) .withCleanConfig(HoodieCleanConfig.newBuilder() - .withCleanerPolicy(HoodieCleaningPolicy.KEEP_LATEST_FILE_VERSIONS).retainFileVersions(1).build()) + .withCleanerPolicy(HoodieCleaningPolicy.KEEP_LATEST_FILE_VERSIONS).retainFileVersions(1).withIncrementalCleaningMode(incrementalCleaningEnabled).build()) .build(); HoodieTableMetadataWriter metadataWriter = SparkHoodieBackedTableMetadataWriter.create(hadoopConf, config, context);