@Test
    public void testMethodArguments() {
        assertThat(classNode.methods)
            .filteredOn(it -> (it.access & (Opcodes.ACC_PUBLIC | Opcodes.ACC_PROTECTED)) != 0)
            .allSatisfy(method -> {
                assertThat(Arrays.asList(Type.getArgumentTypes(method.desc)))
                    .extracting(Type::getClassName)
                    .allSatisfy(it -> assertThat(it).doesNotStartWith(SHADED_PACKAGE));
            });
    }
This test checks that we don't expose any shaded class in our public API.
We use {@link Parameterized} runner here to create a test per public class in Testcontainers' JAR file.
core/src/jarFileTest/java/org/testcontainers/PublicBinaryAPITest.java