public static List<String> parseScope(String spaceDelimitedScope) throws OAuthBearerConfigException {
        List<String> retval = new ArrayList<>();
        for (String individualScopeItem : Objects.requireNonNull(spaceDelimitedScope).split(" ")) {
            if (!individualScopeItem.isEmpty()) {
                if (!isValidScopeItem(individualScopeItem))
                    throw new OAuthBearerConfigException(String.format("Invalid scope value: %s", individualScopeItem));
                retval.add(individualScopeItem);
            }
        }
        return Collections.unmodifiableList(retval);
    }
@Test
    public void invalidScope() {
        for (String invalidScope : new String[] {"\"foo", "\\foo"}) {
            try {
                OAuthBearerScopeUtils.parseScope(invalidScope);
                fail("did not detect invalid scope: " + invalidScope);
            } catch (OAuthBearerConfigException expected) {
                // empty
            }
        }
    }