From 4cba6eb42031b1a4cc3308833116ca5d9ccb1a89 Mon Sep 17 00:00:00 2001 From: Sean Owen Date: Tue, 6 Jan 2015 12:02:08 -0800 Subject: SPARK-4159 [CORE] Maven build doesn't run JUnit test suites This PR: - Reenables `surefire`, and copies config from `scalatest` (which is itself an old fork of `surefire`, so similar) - Tells `surefire` to test only Java tests - Enables `surefire` and `scalatest` for all children, and in turn eliminates some duplication. For me this causes the Scala and Java tests to be run once each, it seems, as desired. It doesn't affect the SBT build but works for Maven. I still need to verify that all of the Scala tests and Java tests are being run. Author: Sean Owen Closes #3651 from srowen/SPARK-4159 and squashes the following commits: 2e8a0af [Sean Owen] Remove specialized SPARK_HOME setting for REPL, YARN tests as it appears to be obsolete 12e4558 [Sean Owen] Append to unit-test.log instead of overwriting, so that both surefire and scalatest output is preserved. Also standardize/correct comments a bit. e6f8601 [Sean Owen] Reenable Java tests by reenabling surefire with config cloned from scalatest; centralize test config in the parent --- pom.xml | 45 +++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 41 insertions(+), 4 deletions(-) (limited to 'pom.xml') diff --git a/pom.xml b/pom.xml index 05f59a9b41..46ff211f91 100644 --- a/pom.xml +++ b/pom.xml @@ -256,7 +256,7 @@ 1.0.0 @@ -266,6 +266,15 @@ 2.3.7 provided + + + org.scalatest + scalatest_${scala.binary.version} + test + @@ -935,19 +944,38 @@ true + org.apache.maven.plugins maven-surefire-plugin - 2.17 + 2.18 + - - true + + **/Test*.java + **/*Test.java + **/*TestCase.java + **/*Suite.java + + ${project.build.directory}/surefire-reports + -Xmx3g -XX:MaxPermSize=${MaxPermGen} -XX:ReservedCodeCacheSize=512m + + true + ${session.executionRootDirectory} + 1 + false + false + ${test_classpath} + true + + org.scalatest scalatest-maven-plugin 1.0 + ${project.build.directory}/surefire-reports . @@ -1159,6 +1187,15 @@ + + + org.apache.maven.plugins + maven-surefire-plugin + + + org.scalatest + scalatest-maven-plugin + -- cgit v1.2.3