@Test
public void testSetScopesIfSpecified() throws Exception {

  String[] scopes = { "foo", "bar" };
  annotationConfig.setScopesIfSpecified(scopes);
  assertEquals(toScopeExpression(scopes), config.getScopeExpression());
  ApiMethodConfig methodConfig =
      config.getApiClassConfig().getMethods().getOrCreate(getResultNoParamsMethod());
  assertEquals(toScopeExpression(scopes), methodConfig.getScopeExpression());
}