diff options
author | gjoranv <gv@verizonmedia.com> | 2021-07-07 12:23:43 +0200 |
---|---|---|
committer | gjoranv <gv@verizonmedia.com> | 2021-07-07 12:23:43 +0200 |
commit | 39c7dced6b2ae36d8b4a2edc03f489148cc8d960 (patch) | |
tree | f1ab47ba82b777db3e14a4cd78263e80a8d3c177 /vespa-maven-plugin | |
parent | b76ae942fe2ddea3ff9341d8e1fd9f76394487b4 (diff) |
Don't attempt to traverse a non-existent test-classes folder.
Diffstat (limited to 'vespa-maven-plugin')
-rw-r--r-- | vespa-maven-plugin/src/main/java/ai/vespa/hosted/plugin/GenerateTestDescriptorMojo.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/vespa-maven-plugin/src/main/java/ai/vespa/hosted/plugin/GenerateTestDescriptorMojo.java b/vespa-maven-plugin/src/main/java/ai/vespa/hosted/plugin/GenerateTestDescriptorMojo.java index 259ae2602c4..69c0e343872 100644 --- a/vespa-maven-plugin/src/main/java/ai/vespa/hosted/plugin/GenerateTestDescriptorMojo.java +++ b/vespa-maven-plugin/src/main/java/ai/vespa/hosted/plugin/GenerateTestDescriptorMojo.java @@ -39,6 +39,8 @@ public class GenerateTestDescriptorMojo extends AbstractMojo { } private void analyzeTestClasses(TestAnnotationAnalyzer analyzer) throws MojoExecutionException { + if (! Files.exists(testClassesDirectory())) return; + try (Stream<Path> files = Files.walk(testClassesDirectory())) { files .filter(f -> f.toString().endsWith(".class")) |