@Override
    protected AddressResolver<InetSocketAddress> newResolver(EventExecutor eventExecutor) {
        return new InetSocketAddressResolver(eventExecutor, new InetNameResolver(eventExecutor) {
            @Override
            protected void doResolve(String hostname, Promise<InetAddress> promise) {
                try {
                    promise.setSuccess(resolver.apply(hostname));
                } catch (Exception e) {
                    promise.setFailure(e);
                }
            }

            @Override
            protected void doResolveAll(String hostname, Promise<List<InetAddress>> promise) {
                try {
                    promise.setSuccess(Collections.singletonList(resolver.apply(hostname)));
                } catch (Exception e) {
                    promise.setFailure(e);
                }
            }
        });
    }
Creates an {@link AddressResolverGroup} with the specified resolver function.

@param resolver the resolver function which returns an {@link InetAddress} for the given hostname
testing-internal/src/main/java/com/linecorp/armeria/internal/testing/MockAddressResolverGroup.java