### Question:
UserGroupAOImpl extends IRODSGenericAO implements UserGroupAO { @Override public List<UserGroup> findAll() throws JargonException { log.info("findAll()"); IRODSGenQueryExecutor irodsGenQueryExecutor = getGenQueryExecutor(); IRODSGenQueryBuilder builder = new IRODSGenQueryBuilder(true, null); try { this.buildUserGroupSelects(builder); } catch (GenQueryBuilderException e) { log.error("query builder exception for query:{}", builder, e); throw new JargonException("error building query", e); } builder.addConditionAsGenQueryField(RodsGenQueryEnum.COL_USER_TYPE, QueryConditionOperators.EQUAL, UserTypeEnum.RODS_GROUP.getTextValue()); IRODSGenQueryFromBuilder irodsQuery = null; try { irodsQuery = builder.exportIRODSQueryFromBuilder(5000); } catch (GenQueryBuilderException e1) { log.error("query builder exception for query:{}", irodsQuery, e1); throw new JargonException("error building query", e1); } IRODSQueryResultSetInterface resultSet; try { resultSet = irodsGenQueryExecutor.executeIRODSQueryAndCloseResult(irodsQuery, 0); } catch (JargonQueryException e) { log.error("query exception for user query:{}", irodsQuery, e); throw new JargonException("error in user group query"); } List<UserGroup> userGroups = new ArrayList<>(); for (IRODSQueryResultRow row : resultSet.getResults()) { userGroups.add(buildUserGroupFromResultSet(row)); } return userGroups; } protected  UserGroupAOImpl(final IRODSSession irodsSession, final IRODSAccount irodsAccount); @Override void addUserGroup(final UserGroup userGroup); @Override void addUserGroupAsGroupAdmin(final UserGroup userGroup); @Override void removeUserGroup(final String userGroupName); @Override void removeUserGroup(final UserGroup userGroup); @Override UserGroup find(final String userGroupId); @Override List<UserGroup> findAll(); @Override UserGroup findByName(final String userGroupName); @Override List<User> listUserGroupMembers(final String userGroupName); @Override List<User> listUserGroupMembers(final String userGroupName, final String targetZone); @Override List<UserGroup> findUserGroups(final String userGroupName); @Override List<UserGroup> findUserGroupsForUserInZone(final String userName, final String targetZone); @Override List<UserGroup> findUserGroupsForUser(final String userName); @Override boolean isUserInGroup(final String userName, final String groupName); @Override void addUserToGroup(final String userGroupName, final String userName, final String zoneName); @Override void addUserToGroupAsGroupAdmin(final String userGroupName, final String userName, final String zoneName); @Override void removeUserFromGroup(final String userGroupName, final String userName, final String zoneName); @Override List<UserGroup> findUserGroups(String userGroupName, boolean caseInsensitive); @Override List<String> findUserGroupNames(String userGroupName, boolean caseInsensitive);  }### Answer:
@Test public final void testFindAll() throws Exception { IRODSProtocolManager irodsConnectionManager = IRODSSimpleProtocolManager.instance(); IRODSAccount irodsAccount = testingPropertiesHelper.buildIRODSAccountFromTestProperties(testingProperties); IRODSSession irodsSession = IRODSSession.instance(irodsConnectionManager); IRODSAccessObjectFactory accessObjectFactory = IRODSAccessObjectFactoryImpl.instance(irodsSession); UserGroupAO userGroupAO = accessObjectFactory.getUserGroupAO(irodsAccount); List<UserGroup> userGroup = userGroupAO.findAll(); irodsSession.closeSession(); Assert.assertNotNull("no user group returned", userGroup); Assert.assertFalse("no user groups returned for query", userGroup.isEmpty()); }