when(tradingService.findQuotesBySymbols(anySetOf(String.class))).thenReturn(quotes());
when(tradingService.findAccount(eq(ACCOUNT_ID))).thenReturn(account());
when(tradingService.findAccountByProfile(any(Accountprofile.class))).thenReturn(account());
when(tradingService.findPortfolioSummary(eq(ACCOUNT_ID))).thenReturn(portfolioSummary());
when(tradingService.findMarketSummary()).thenReturn(marketSummary());
when(tradingService.login(eq(USER_ID), eq(PASSWORD))).thenReturn(accountProfile());
when(tradingService.login(eq(BAD_USER_ID), eq(BAD_PASSWORD))).thenReturn(null);
when(tradingService.findHoldingSummary(eq(ACCOUNT_ID))).thenReturn(holdingSummary());
doNothing().when(tradingService).logout(any(String.class));
return tradingService;