source: class MultiChoiceToolbarHelperTest {
  
      private static final String TOOLBAR_ERROR_MESSAGE;
      @Mock private MultiChoiceToolbar mMockMultiChoiceToolbar;
      @Mock private AppCompatActivity mMockAppCompatActivity;
      @Mock private ActionBar mMockActionBar;
      @Mock private Toolbar mMockToolbar;
      @Mock private Window mMockWindow;
      @Mock private MultiChoiceToolbar.Listener mListener;
      private MultiChoiceToolbarHelper mCut;
  
      @Test
      public void testGivenZeroItemSelectedWhenUpdateToolbarThenDefaultBackgroundSet() throws Exception {
  
target:         // Given
          int itemSelected = 0;
  
          // When
          mCut.updateToolbar(itemSelected);
  
          // Then
          verify(mMockActionBar, times(1)).setBackgroundDrawable(any(ColorDrawable.class));
          verify(mMockMultiChoiceToolbar, times(1)).getDefaultPrimaryColor();
      }
  
  }