This section will show how the previously created example application can be configured and run as a JUnit test within the IDE. Setting up an integration test that can be executed after every change will avoid a full package/deploy cycle to run on a cluster just to find basic issues. It allows for efficient debugging and will also come in handy when setting up continuous integration for a project.
The test covers the entire DAG and will run the application in embedded mode. In embedded mode, all operators and containers share the JUnit JVM. Containers are threads (instead of separate processes) but the data flow still behaves as if operators lived in separate processes. This means operators execute asynchronously as they would in a distributed cluster and data is transferred over the loopback interface (if that's how the streams are configured).
@Test public void testApplication() throws Exception { EmbeddedAppLauncher<?> launcher =...