@Test
public void invalidSubChildPath() throws Throwable {

    MinimalFactoryTestService f = new MinimalFactoryTestService();
    f.setChildServiceCaps(EnumSet.of(ServiceOption.PERSISTENCE));
    f = (MinimalFactoryTestService) this.host
            .startServiceAndWait(f, UUID.randomUUID().toString(), null);
    this.host.waitForServiceAvailable(f.getUri());
    // create a child
    MinimalTestServiceState initialState = (MinimalTestServiceState) this.host
            .buildMinimalTestState();
    initialState.documentSelfLink = "foo";
    Operation post = Operation
            .createPost(f.getUri())
            .setBody(initialState);
    this.host.sendAndWaitExpectSuccess(post);
    // confirm child is running with a GET
    Operation get = Operation
            .createGet(UriUtils.extendUri(f.getUri(), initialState.documentSelfLink));
    this.host.sendAndWaitExpectSuccess(get);
    // create a bogus URI with a nested suffix, should result in error
    TestRequestSender sender = this.host.getTestRequestSender();
    get = Operation
            .createGet(UriUtils.extendUri(f.getUri(),
                    initialState.documentSelfLink + "/sub-child"));
    sender.sendAndWaitFailure(get);
}