### Question:
AuthScopeRdbmsDao extends AuthScopeDao { @Override public AuthScope read(String scopeName) throws AuthServerException { Set<String> userGroups = new HashSet<>(); String scopeId = null; Connection connection = null; PreparedStatement statement = null; ResultSet resultSet = null; try { connection = getConnection(); statement = connection.prepareStatement(RdbmsConstants.PS_SELECT_AUTH_SCOPE); statement.setString(1, scopeName); resultSet = statement.executeQuery(); while (resultSet.next()) { if (Objects.isNull(scopeId)) { scopeId = resultSet.getString(1); } String userGroup = resultSet.getString(2); if (Objects.nonNull(userGroup)) { userGroups.add(userGroup); } } } catch (SQLException e) { throw new AuthServerException("Error occurred while retrieving scope for name : " + scopeName, e); } finally { close(connection, statement, resultSet); } if (Objects.nonNull(scopeId)) { return new AuthScope(scopeName, userGroups); } return null; } AuthScopeRdbmsDao(DataSource dataSource); @Override AuthScope read(String scopeName); @Override List<AuthScope> readAll(); @Override void update(String scopeName, List<String> userGroups);  }### Answer:
@Test public void testRead() throws AuthServerException { AuthScope authScope = authScopeDao.read("exchanges:test"); Assert.assertEquals(authScope.getScopeName(), "exchanges:test"); Assert.assertEquals(authScope.getUserGroups().size(), 1); }