blob: 5dff69c1fe2b57c86ca68c81d0e336ed61c0f120 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
import java.io.*;
import java.util.zip.*;
File file = new File( basedir, "target/test-1.0.jar" );
if (!file.isFile()) {
throw new FileNotFoundException( "Could not find generated JAR: " + file );
}
ZipFile zipFile = new ZipFile(file);
try {
if (zipFile.getEntry("META-INF/lib/")!=null) {
throw new FileNotFoundException("The dependency sonar-surefire-plugin must not be copied in the plugin");
}
} finally {
zipFile.close();
}
|