Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FLINK-7554][Tests] Add a testing RuntimeContext to test utilities #6148

Closed
wants to merge 1 commit into from

Conversation

@buptljy
Copy link
Contributor

buptljy commented Jun 11, 2018

What is the purpose of the change

This pull request adds a TestingRuntimeContext to help developers test their own user-defined functions like CoprocessFunction instead of testing the whole pipeline.

Brief change log

  • TestingRuntimeContext can be directly used in unit testing of both dataset functions and datastream functions, including the support of broadcastVariable, state, accumulator and so on.
  • Documents are written in udf_test, including examples of Java and Scala.

Verifying this change

  • This change has already been verified in new unit testing files in test directory, org.apache.flink.streaming.api.functions.test.TestingRuntimeContextTest and org.apache.flink.streaming.api.functions.test.TestingRuntimeContextTest.

Documentation

  • This pull request is a new feature.
  • Related documents are written in docs directory.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.