These tests are ok but could be modernised a bit

- use `safeAwait` instead of awaiting the latch directly
- move assertions into handler, avoiding the need for `responseHolder`
- would it be better to use an `ActionListenerResponseHandler` rather than a raw `TransportResponseHandler`?
server/src/test/java/org/elasticsearch/action/admin/cluster/configuration/TransportClearVotingConfigExclusionsActionTests.java
expectSuccess(r -> {
                responseHolder.set(r);
                countDownLatch.countDown();
            })
        );
        final ClusterState.Builder builder = builder(clusterService.state());
        builder.nodes(DiscoveryNodes.builder(clusterService.state().nodes()).remove(otherNode1).remove(otherNode2));
        setState(clusterService, builder);
        assertTrue(countDownLatch.await(30, TimeUnit.SECONDS));
        assertThat(clusterService.getClusterApplierService().state().getVotingConfigExclusions(), empty());
    }
    public void testCannotClearVotingConfigurationWhenItIsDisabled() {
        final CountDownLatch countDownLatch = new CountDownLatch(1);
        final SetOnce<TransportException> exceptionHolder = new SetOnce<>();
        reconfigurator.disableUserVotingConfigModifications();
        transportService.sendRequest(
            localNode,
            ClearVotingConfigExclusionsAction.NAME,
            new ClearVotingConfigExclusionsRequest(),
            expectError(e -> {
                exceptionHolder.set(e);
                countDownLatch.countDown();
            })
        );
        safeAwait(countDownLatch);
        final Throwable rootCause = exceptionHolder.get().getRootCause();
        assertThat(rootCause, instanceOf(IllegalStateException.class));
        assertThat(rootCause.getMessage(), startsWith("Unable to modify the voting configuration"));
    }
    private TransportResponseHandler<ActionResponse.Empty> expectSuccess(Consumer<ActionResponse.Empty> onResponse) {