samedi 13 février 2021

How to provide some library from maven to Google Compile-Testing

I'm writing a tests for my annotation processor with Google Compile-Testing and JUnit.

How to provide some libraries, which present at maven(as example, "somegroup:somelib:1.0"), to compilation?

Compilation compilation = Compiler.javac().withProcessors(new MyProcessor())
                .withClasspath(???) //What's there to use?
                .compile(
                        JavaFileObjects.forResource("path/to/SomeClass.java")
                        ...
                );

Aucun commentaire:

Enregistrer un commentaire