@Test public void onEnterScope() throws Exception { ScreenListener listener = mock(ScreenListener.class); screenTracker.addListener(listener); screenTracker.onEnterScope("scope", mock(View.class)); verify(listener).onScreenChanged(any()); }
@Override public void onEnterScope(String scopeName, View view) { currentScreen.enterScope(scopeName, view); fireOnScreenChanged(); }
ScreenTracker extends SimpleActivityLifecycleCallbacks implements PhialScopeNotifier.OnScopeChangedListener { @Override public void onEnterScope(String scopeName, View view) { currentScreen.enterScope(scopeName, view); fireOnScreenChanged(); } }
ScreenTracker extends SimpleActivityLifecycleCallbacks implements PhialScopeNotifier.OnScopeChangedListener { @Override public void onEnterScope(String scopeName, View view) { currentScreen.enterScope(scopeName, view); fireOnScreenChanged(); }  }
ScreenTracker extends SimpleActivityLifecycleCallbacks implements PhialScopeNotifier.OnScopeChangedListener { @Override public void onEnterScope(String scopeName, View view) { currentScreen.enterScope(scopeName, view); fireOnScreenChanged(); }  void addListener(ScreenListener listener); void removeListener(ScreenListener listener); Screen getCurrentScreen(); @Override void onActivityResumed(Activity activity); @Override void onActivityPaused(Activity activity); @Override void onEnterScope(String scopeName, View view); @Override void onExitScope(String scopeName); boolean matchesAny(Set<TargetScreen> targetScreen); View findTarget(int id); }
ScreenTracker extends SimpleActivityLifecycleCallbacks implements PhialScopeNotifier.OnScopeChangedListener { @Override public void onEnterScope(String scopeName, View view) { currentScreen.enterScope(scopeName, view); fireOnScreenChanged(); }  void addListener(ScreenListener listener); void removeListener(ScreenListener listener); Screen getCurrentScreen(); @Override void onActivityResumed(Activity activity); @Override void onActivityPaused(Activity activity); @Override void onEnterScope(String scopeName, View view); @Override void onExitScope(String scopeName); boolean matchesAny(Set<TargetScreen> targetScreen); View findTarget(int id);  }