Change the pom.xml and remove some use of Java 1.5 features to reduce the
number of errors produced by "mvn package".
This commit is contained in:
9
pom.xml
9
pom.xml
@@ -10,4 +10,13 @@
|
||||
<build>
|
||||
<finalName>luaj</finalName>
|
||||
</build>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>junit</groupId>
|
||||
<artifactId>junit</artifactId>
|
||||
<version>3.8.1</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
|
||||
@@ -5,6 +5,7 @@ import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.OutputStream;
|
||||
import java.util.HashMap;
|
||||
import java.util.Iterator;
|
||||
import java.util.zip.ZipEntry;
|
||||
import java.util.zip.ZipInputStream;
|
||||
|
||||
@@ -23,8 +24,8 @@ public class StandardTest extends TestCase {
|
||||
public static Test suite() throws IOException {
|
||||
ZipEntry file;
|
||||
|
||||
final HashMap<String, Proto> tests = new HashMap<String, Proto>();
|
||||
final HashMap<String, String> results = new HashMap<String, String>();
|
||||
final HashMap tests = new HashMap();
|
||||
final HashMap results = new HashMap();
|
||||
|
||||
InputStream zipStream = StandardTest.class.getResourceAsStream( "/standard-tests.zip" );
|
||||
ZipInputStream testSuiteArchive = new ZipInputStream( zipStream );
|
||||
@@ -44,9 +45,10 @@ public class StandardTest extends TestCase {
|
||||
|
||||
TestSuite suite = new TestSuite();
|
||||
|
||||
for ( final String test : tests.keySet() ) {
|
||||
final Proto code = tests.get( test );
|
||||
final String expectedResult = results.get( test );
|
||||
for ( Iterator keys = tests.keySet().iterator(); keys.hasNext(); ) {
|
||||
String test = (String)keys.next();
|
||||
final Proto code = (Proto)tests.get( test );
|
||||
final String expectedResult = (String)results.get( test );
|
||||
|
||||
if ( code != null && expectedResult != null ) {
|
||||
suite.addTest( new StandardTest( test, code, expectedResult ) );
|
||||
|
||||
Reference in New Issue
Block a user