ThreadsComponentFactory implements ComponentFactory { @Override public Topology createTopology(String topoName) { return new ThreadsTopology(topoName); }  @Override ProcessingItem createPi(Processor processor); @Override ProcessingItem createPi(Processor processor, int paralellism); @Override EntranceProcessingItem createEntrancePi(EntranceProcessor entranceProcessor); @Override Stream createStream(IProcessingItem sourcePi); @Override Topology createTopology(String topoName);  }
@Test public void testCreateTopology() { Topology topology = factory.createTopology(topoName); assertNotNull("Topology created is null.",topology); assertEquals("Topology created is not a ThreadsTopology.",ThreadsTopology.class,topology.getClass()); }