@Test public void testRoute() { LinkedHashMap<String,Step> stepList = new LinkedHashMap<>(); stepList.put("foo",stepMock1); stepList.put("bar",stepMock2); replay(); Step[] steps = router.route(docMock, stepList); assertTrue(Arrays.asList(steps).contains(stepMock1)); assertTrue(Arrays.asList(steps).contains(stepMock2)); }
@Override public Step[] route(Document doc, LinkedHashMap<String, Step> nextSteps) { return nextSteps.values().toArray(new Step[nextSteps.size()]); }
DuplicateToAll implements Router { @Override public Step[] route(Document doc, LinkedHashMap<String, Step> nextSteps) { return nextSteps.values().toArray(new Step[nextSteps.size()]); } }
DuplicateToAll implements Router { @Override public Step[] route(Document doc, LinkedHashMap<String, Step> nextSteps) { return nextSteps.values().toArray(new Step[nextSteps.size()]); }  }
DuplicateToAll implements Router { @Override public Step[] route(Document doc, LinkedHashMap<String, Step> nextSteps) { return nextSteps.values().toArray(new Step[nextSteps.size()]); }  @Override Step[] route(Document doc, LinkedHashMap<String, Step> nextSteps); @Override String getName(); }
DuplicateToAll implements Router { @Override public Step[] route(Document doc, LinkedHashMap<String, Step> nextSteps) { return nextSteps.values().toArray(new Step[nextSteps.size()]); }  @Override Step[] route(Document doc, LinkedHashMap<String, Step> nextSteps); @Override String getName();  }