@Test
    public void shouldCreateRandomUuidBasedPasswords() {
        try (
            // withRandomPassword {
            Neo4jContainer<?> neo4jContainer = new Neo4jContainer<>("neo4j:4.4").withRandomPassword();
            // }
        ) {
            // It will throw an exception if it's not UUID parsable.
            assertThatNoException().isThrownBy(neo4jContainer::configure);
            // This basically is always true at if the random password is UUID-like.
            assertThat(neo4jContainer.getAdminPassword())
                .satisfies(password -> assertThat(UUID.fromString(password).toString()).isEqualTo(password));
        }
    }
Tests of functionality special to the Neo4jContainer.
modules/neo4j/src/test/java/org/testcontainers/containers/Neo4jContainerTest.java