summaryrefslogtreecommitdiffstats
path: root/sql/src/test
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2010-02-18 17:20:15 -0800
committerElliott Hughes <enh@google.com>2010-02-19 10:35:06 -0800
commit7ee3a061452c5a7e5c8e661219a1f08a14171858 (patch)
treef995fb4c053e4c68a86909aa72aee284cb39133a /sql/src/test
parent1d1f9244611a8ba3be65795d4ea6e84bcecdb89d (diff)
downloadlibcore-7ee3a061452c5a7e5c8e661219a1f08a14171858.zip
libcore-7ee3a061452c5a7e5c8e661219a1f08a14171858.tar.gz
libcore-7ee3a061452c5a7e5c8e661219a1f08a14171858.tar.bz2
Resync a load of tests with upstream, make our build faster.
I started off with a mission to remove uses of dalvik.annotation.* (stuff like @TestTargetNew and other useless junk that just makes it harder to stay in sync with upstream). I wrote a script to go through tests showing me the diff between what we have and what upstream has, thinking that in cases where upstream has also added tests, I may as well pull them in at the same time... ...but I didn't realize how close we were to having dx fill its 1.5GiB heap. After trying various alternatives, I decided to bite the bullet and break core-tests up into one .jar per module. This adds parallelism back into this, the slowest part of our build. (I can do even better, but I'll do that in a separate patch, preferably after we've merged recent changes from master.) Only a couple of dependencies were problematic: the worthless TestSuiteFactory which already contained a comment suggesting we get rid of it, and the fact that some tests -- most notably the concurrent ones -- also contained main methods that started the JUnit tty-based TestRunner. (In the long run, we want to be running the harmony tests directly from a pristine "svn co" of upstream, using DalvikRunner. But this will be a big help in the meantime, and starts the work of getting our current copy of the tests into a state where we can start to extract any meaningful changes/additions we've made.)
Diffstat (limited to 'sql/src/test')
-rw-r--r--sql/src/test/java/org/apache/harmony/sql/tests/java/sql/AllTests.java7
-rw-r--r--sql/src/test/java/org/apache/harmony/sql/tests/javax/sql/AllTests.java7
-rw-r--r--sql/src/test/java/tests/SQLite/AllTests.java2
-rw-r--r--sql/src/test/java/tests/java/sql/AllTests.java7
-rw-r--r--sql/src/test/java/tests/sql/AllTests.java7
5 files changed, 5 insertions, 25 deletions
diff --git a/sql/src/test/java/org/apache/harmony/sql/tests/java/sql/AllTests.java b/sql/src/test/java/org/apache/harmony/sql/tests/java/sql/AllTests.java
index 58c670a..1b0bb59 100644
--- a/sql/src/test/java/org/apache/harmony/sql/tests/java/sql/AllTests.java
+++ b/sql/src/test/java/org/apache/harmony/sql/tests/java/sql/AllTests.java
@@ -24,13 +24,8 @@ import junit.framework.TestSuite;
*/
public class AllTests {
-
- public static void main(String[] args) {
- junit.textui.TestRunner.run(AllTests.suite());
- }
-
public static Test suite() {
- TestSuite suite = tests.TestSuiteFactory.createTestSuite("All tests for package org.apache.harmony.sql.tests.java.sql;");
+ TestSuite suite = new TestSuite("All tests for package org.apache.harmony.sql.tests.java.sql;");
// $JUnit-BEGIN$
suite.addTestSuite(BatchUpdateExceptionTest.class);
diff --git a/sql/src/test/java/org/apache/harmony/sql/tests/javax/sql/AllTests.java b/sql/src/test/java/org/apache/harmony/sql/tests/javax/sql/AllTests.java
index abbb8b0..8183bbf 100644
--- a/sql/src/test/java/org/apache/harmony/sql/tests/javax/sql/AllTests.java
+++ b/sql/src/test/java/org/apache/harmony/sql/tests/javax/sql/AllTests.java
@@ -24,13 +24,8 @@ import junit.framework.TestSuite;
*/
public class AllTests {
-
- public static void main(String[] args) {
- junit.textui.TestRunner.run(AllTests.suite());
- }
-
public static Test suite() {
- TestSuite suite = tests.TestSuiteFactory.createTestSuite("All tests for package org.apache.harmony.sql.tests.javax.sql;");
+ TestSuite suite = new TestSuite("All tests for package org.apache.harmony.sql.tests.javax.sql;");
// $JUnit-BEGIN$
suite.addTestSuite(ConnectionEventTest.class);
diff --git a/sql/src/test/java/tests/SQLite/AllTests.java b/sql/src/test/java/tests/SQLite/AllTests.java
index 2cf0f61..e2aa55c 100644
--- a/sql/src/test/java/tests/SQLite/AllTests.java
+++ b/sql/src/test/java/tests/SQLite/AllTests.java
@@ -23,7 +23,7 @@ public class AllTests {
//All tests executed with sqlite3 only
public static Test suite() {
- TestSuite suite = tests.TestSuiteFactory.createTestSuite("Tests for SQLite");
+ TestSuite suite = new TestSuite("Tests for SQLite");
//$JUnit-BEGIN$
suite.addTestSuite(DatabaseTest.class);
suite.addTestSuite(JDBCDriverFunctionalTest.class);
diff --git a/sql/src/test/java/tests/java/sql/AllTests.java b/sql/src/test/java/tests/java/sql/AllTests.java
index c6a2bff..5c9345b 100644
--- a/sql/src/test/java/tests/java/sql/AllTests.java
+++ b/sql/src/test/java/tests/java/sql/AllTests.java
@@ -24,13 +24,8 @@ import junit.framework.TestSuite;
*/
public class AllTests {
-
- public static void main(String[] args) {
- junit.textui.TestRunner.run(AllTests.suite());
- }
-
public static Test suite() {
- TestSuite suite = tests.TestSuiteFactory.createTestSuite("All tests for package tests.java.sql;");
+ TestSuite suite = new TestSuite("All tests for package tests.java.sql;");
// $JUnit-BEGIN$
suite.addTestSuite(MultiThreadAccessTest.class);
diff --git a/sql/src/test/java/tests/sql/AllTests.java b/sql/src/test/java/tests/sql/AllTests.java
index 4d59cd4..6eda690 100644
--- a/sql/src/test/java/tests/sql/AllTests.java
+++ b/sql/src/test/java/tests/sql/AllTests.java
@@ -23,13 +23,8 @@ import junit.framework.TestSuite;
* Test suite that includes all tests for the Math project.
*/
public class AllTests {
-
- public static void main(String[] args) {
- junit.textui.TestRunner.run(AllTests.suite());
- }
-
public static Test suite() {
- TestSuite suite = tests.TestSuiteFactory.createTestSuite("All SQL test suites");
+ TestSuite suite = new TestSuite("All SQL test suites");
// $JUnit-BEGIN$
suite.addTest(org.apache.harmony.sql.tests.java.sql.AllTests.suite());
suite.addTest(org.apache.harmony.sql.tests.javax.sql.AllTests.suite());