Search in sources :

Example 1 with Bargain

use of vwap.Bargain in project streamsx.topology by IBMStreams.

the class VwapTest method testVwap.

@Test
public void testVwap() throws Exception {
    // Invokes an SPL operator so cannot run in embedded.
    assumeSPLOk();
    TStream<Bargain> bargains = Vwap.createVwapTopology();
    bargains = Vwap.realBargains(bargains);
    Topology topology = bargains.topology();
    Tester tester = topology.getTester();
    Condition<Long> expectedCount = tester.atLeastTupleCount(bargains, 2200);
    complete(tester, expectedCount, 120, TimeUnit.SECONDS);
    assertTrue(expectedCount.toString(), expectedCount.valid());
}
Also used : Tester(com.ibm.streamsx.topology.tester.Tester) Bargain(vwap.Bargain) Topology(com.ibm.streamsx.topology.Topology) TestTopology(com.ibm.streamsx.topology.test.TestTopology) Test(org.junit.Test)

Aggregations

Topology (com.ibm.streamsx.topology.Topology)1 TestTopology (com.ibm.streamsx.topology.test.TestTopology)1 Tester (com.ibm.streamsx.topology.tester.Tester)1 Test (org.junit.Test)1 Bargain (vwap.Bargain)1