@Test
public void testInvalidMethodName() throws Exception {

  config.setName("testApi");
  config.getApiClassConfig().getMethods().get(
      methodToEndpointMethod(TestEndpoint.class.getMethod("failWrapped"))).setName(".");
  try {
    validator.validate(config);
    fail("Expected InvalidMethodNameException.");
  } catch (InvalidMethodNameException expected) {
  }
}