@Test public void testLoggedInTime() { MessageInputStream mis = mock(MessageInputStream.class); MessageOutputStream mos = mock(MessageOutputStream.class); MessageIO messageIO = new MessageIO(mis, mos); ClientUser clientUser = mock(ClientUser.class); long random = (long) (Math.random() * 1000); AuthClient authClient = new AuthClient(messageIO, clientUser); authClient.getLoginTracker().setLoggedInTime(random); Assert.assertEquals(authClient.getLoginTracker().getLoggedInTime(), random, "Login time was incorrect."); }
public LoginTracker getLoginTracker() { return loginTracker; }
AuthClient extends Client { public LoginTracker getLoginTracker() { return loginTracker; } }
AuthClient extends Client { public LoginTracker getLoginTracker() { return loginTracker; } AuthClient(MessageIO messageIO, ClientUser user); }
AuthClient extends Client { public LoginTracker getLoginTracker() { return loginTracker; } AuthClient(MessageIO messageIO, ClientUser user); static Message generateLogoutRequest(); static Message generateLoginRequest(ClientUser user); LoginTracker getLoginTracker(); ClientUser getUser(); }
AuthClient extends Client { public LoginTracker getLoginTracker() { return loginTracker; } AuthClient(MessageIO messageIO, ClientUser user); static Message generateLogoutRequest(); static Message generateLoginRequest(ClientUser user); LoginTracker getLoginTracker(); ClientUser getUser();  }