Assert.assertFalse(this.service.validateUser("guy", "pass"));
}
@Test
public void findByLogin() {
User u = mock(User.class);
UserCurator curator = mock(UserCurator.class);
RoleCurator roleCurator = mock(RoleCurator.class);
UserServiceAdapter dusa = new DefaultUserServiceAdapter(curator,
roleCurator);
when(curator.findByLogin(anyString())).thenReturn(u);
User foo = dusa.findByLogin("foo");
assertNotNull(foo);
assertEquals(foo, u);
}