1
0

[HUDI-1418] Set up flink client unit test infra (#2281)

This commit is contained in:
Gary Li
2020-12-31 08:57:22 +08:00
committed by GitHub
parent 605b617cfa
commit c5e8a024f6
23 changed files with 642 additions and 125 deletions

View File

@@ -35,6 +35,7 @@ import java.io.IOException;
public class HoodieCommonTestHarness {
protected String basePath = null;
protected transient HoodieTestDataGenerator dataGen = null;
protected transient HoodieTableMetaClient metaClient;
@TempDir
public java.nio.file.Path tempDir;
@@ -52,6 +53,24 @@ public class HoodieCommonTestHarness {
}
}
/**
* Initializes a test data generator which used to generate test datas.
*
*/
protected void initTestDataGenerator() {
dataGen = new HoodieTestDataGenerator();
}
/**
* Cleanups test data generator.
*
*/
protected void cleanupTestDataGenerator() {
if (dataGen != null) {
dataGen = null;
}
}
/**
* Initializes an instance of {@link HoodieTableMetaClient} with a special table type specified by
* {@code getTableType()}.