@Test
    public void shouldFailAuthenticateWithPlainTextBadUsername() {
        final Cluster cluster = TestClientFactory.build().auth(basic("marko", "password")).create();
        final Client client = cluster.connect();

        try {
            client.submit("g.inject(2)").all().get();
        } catch (Exception ex) {
            final Throwable root = ExceptionHelper.getRootCause(ex);
            assertEquals(ResponseException.class, root.getClass());
            assertEquals("Username and/or password are incorrect", root.getMessage());
        } finally {
            cluster.close();
        }
    }
Configure specific Gremlin Server settings for specific tests.
gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/server/GremlinServerAuthIntegrateTest.java