ComposerController { void sendCancelBroadcast() { final Intent intent = new Intent(TWEET_COMPOSE_CANCEL); intent.setPackage(composerView.getContext().getPackageName()); composerView.getContext().sendBroadcast(intent); } ComposerController(final ComposerView composerView, TwitterSession session, Uri imageUri,
            String text, String hashtags, ComposerActivity.Finisher finisher);   ComposerController(final ComposerView composerView, TwitterSession session, Uri imageUri,
            String text, String hashtags, ComposerActivity.Finisher finisher,
            DependencyProvider dependencyProvider);   }
@Test public void testSendCancelBroadcast() { controller = new ComposerController(mockComposerView, mockTwitterSession, Uri.EMPTY, ANY_TEXT, ANY_HASHTAG, mockFinisher, mockDependencyProvider); final ArgumentCaptor<Intent> intentCaptor = ArgumentCaptor.forClass(Intent.class); controller.sendCancelBroadcast(); verify(mockContext).sendBroadcast(intentCaptor.capture()); final Intent capturedIntent = intentCaptor.getValue(); assertEquals(TWEET_COMPOSE_CANCEL, capturedIntent.getAction()); }