[FLINK-39377][table] Add initial implementation of ProcessTableFunctionTestHarness by autophagy · Pull Request #27928 · apache/flink
…onTestHarness This commit introduces an initial implementation of a test harness for PTFs, for use in unit tests that do not require a running Flink cluster. The implementation supports setting up the harness by configuration various test parameters, like fixtures for scalar arguments, datatypes for table arguments and partition settings for table arguments with set semantics. The harness on build does type and structure validation, as well as ensuring the test setup can handle the arguments defined on the PTF. It supports PTFs that use scalar, set semantic table and row semantic table arguments, as well as PTFs that have multiple of each. It supports PASS_COLUMN_THROUGH and OPTIONAL_PARTITION_BY traits. It currently does not support State, or Context (so no timers). It also does not enforce some static argument traits like SUPPORTS_UPDATES, REQUIRE_UPDATE_BEFORE.