@Test public void testPipelineInterpolate() { final float alpha = 1.0f; mockery.checking(new Expectations() { { oneOf(operation1).interpolate(gc, alpha); oneOf(operation2).interpolate(gc, alpha); } }); pipeline.interpolate(gc, alpha); }
public void interpolate(GameContainer gc, float alpha) { for(RenderOperation stage : operations) { stage.interpolate(gc, alpha); } }
RenderPipeline { public void interpolate(GameContainer gc, float alpha) { for(RenderOperation stage : operations) { stage.interpolate(gc, alpha); } } }
RenderPipeline { public void interpolate(GameContainer gc, float alpha) { for(RenderOperation stage : operations) { stage.interpolate(gc, alpha); } } RenderPipeline(); }
RenderPipeline { public void interpolate(GameContainer gc, float alpha) { for(RenderOperation stage : operations) { stage.interpolate(gc, alpha); } } RenderPipeline(); void update(GameContainer gc, float delta); void interpolate(GameContainer gc, float alpha); void render(GameContainer gc, Graphics g); void add(RenderOperation operation); void remove(RenderOperation operation); boolean isOneWay(); void setOneWay(boolean oneWay); }
RenderPipeline { public void interpolate(GameContainer gc, float alpha) { for(RenderOperation stage : operations) { stage.interpolate(gc, alpha); } } RenderPipeline(); void update(GameContainer gc, float delta); void interpolate(GameContainer gc, float alpha); void render(GameContainer gc, Graphics g); void add(RenderOperation operation); void remove(RenderOperation operation); boolean isOneWay(); void setOneWay(boolean oneWay);  }