@Test
public void testMockInvokerInvoke_failmock() {

    URL url = URL.valueOf("remote://1.2.3.4/" + IHelloService.class.getName())
            .addParameter(MOCK_KEY, "fail:return null")
            .addParameter(REFER_KEY, URL.encode(PATH_KEY + "=" + IHelloService.class.getName()))
            .addParameter("invoke_return_error", "true");
    URL mockUrl = URL.valueOf("mock://localhost/" + IHelloService.class.getName()
            + "?getSomething.mock=return aa").addParameters(url.getParameters());
    Protocol protocol = new MockProtocol();
    Invoker<IHelloService> mInvoker1 = protocol.refer(IHelloService.class, mockUrl);
    Invoker<IHelloService> cluster = getClusterInvokerMock(url, mInvoker1);
    //Configured with mock
    RpcInvocation invocation = new RpcInvocation();
    invocation.setMethodName("getSomething");
    Result ret = cluster.invoke(invocation);
    Assertions.assertEquals("aa", ret.getValue());
    // If no mock was configured, return null directly
    invocation = new RpcInvocation();
    invocation.setMethodName("getSomething2");
    ret = cluster.invoke(invocation);
    Assertions.assertNull(ret.getValue());
    // If no mock was configured, return null directly
    invocation = new RpcInvocation();
    invocation.setMethodName("sayHello");
    ret = cluster.invoke(invocation);
    Assertions.assertNull(ret.getValue());
}