Commit 0352c889 authored by Christian Wulf's avatar Christian Wulf

#362: testing sinks works

parent 7f226638
......@@ -9,6 +9,7 @@ import java.util.List;
import org.junit.Test;
import teetime.stage.CollectorSink;
import teetime.stage.Counter;
import teetime.stage.InitialElementProducer;
......@@ -60,6 +61,12 @@ public class StageTesterTest {
@Test
public void testSink() throws Exception {
CollectorSink<Integer> consumer = new CollectorSink<>();
test(consumer).and()
.send(1, 2, 3).to(consumer.getInputPort()).and()
.start();
assertThat(consumer.getElements(), contains(1, 2, 3));
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment