@Test
public void testInvalidDomain() {

  try {
    ServiceContext c = ServiceContext.create("123.com:abc", "xyz");
    fail("invalid domain should have failed");
  } catch (IllegalArgumentException e) {
    // expected
  }
}