@Test
 public void testDeleteUser() throws Exception {
   LOGGER.debug("test: DeleteUser");
   List<User> users = userDao.getAllUsers();
   Integer usersSize = users.size();
   assertTrue(users.size() > 0);
   userDao.deleteUser(users.get(0).getId_user());
   assertTrue(usersSize - 1 == userDao.getAllUsers().size());
 }
 @Test
 public void testGetAllUsers() throws Exception {
   LOGGER.debug("test: getAllUsers");
   List<User> users = userDao.getAllUsers();
   LOGGER.debug(">> Lastname 1 = {} ", users.get(0).getLastname());
   LOGGER.debug(">> Lastname 2 = {} ", users.get(1).getLastname());
   assertTrue(users.size() == 2);
 }
示例#3
0
 public void testGetAllForAccount() throws Exception {
   List<User> list = dao.getAllUsers(1L);
   assertTrue(list.size() == 4);
 }
示例#4
0
  public List<AppUser> getAllUsers() {

    return userDao.getAllUsers();
  }