SketchClearer implements SketchClearListener { public void clearSketch() { zenSketchView.clear(); AnalyticsTracker.INSTANCE.trackClearSketch(); } SketchClearer(ZenSketch zenSketch, ZenSketchView zenSketchView); static SketchClearer newInstance(ZenSketchView zenSketchView); void clearSketch(); @Override void onSketchCleared();  }
@Test public void testThatWhenClearSketchIsPerformedThenZenSketchIsCleared() { sketchClearer.clearSketch(); verify(zenSketchView).clear(); }