blob: 5715c00b23ac2f16127d1aee9b57fdd1efcb5bbc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
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/commons-email-1.2.jar")==null) {
throw new FileNotFoundException("The dependency commons-email must be copied in JAR");
}
} finally {
zipFile.close();
}
|