Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
Fix unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex Eng committed Dec 18, 2012
1 parent 5fe4367 commit 8d9ddd0
Showing 1 changed file with 5 additions and 1 deletion.
Expand Up @@ -47,16 +47,20 @@ public class TransFilterPresenterTest
@Captor
private ArgumentCaptor<ValueChangeHandler<Boolean>> filterChangeHandlerCaptor;

private UserConfigHolder configHolder = new UserConfigHolder();

@BeforeMethod
public void setUp() throws Exception
{
MockitoAnnotations.initMocks(this);
presenter = new TransFilterPresenter(display, eventBus, history, userOptionsService);

when(userOptionsService.getConfigHolder()).thenReturn(configHolder);
when(display.getNeedReviewChk()).thenReturn(needReviewChk);
when(display.getTranslatedChk()).thenReturn(translatedChk);
when(display.getUntranslatedChk()).thenReturn(untranslatedChk);

presenter = new TransFilterPresenter(display, eventBus, history, userOptionsService);

verify(display).setListener(presenter);
}

Expand Down

0 comments on commit 8d9ddd0

Please sign in to comment.