aboutsummaryrefslogtreecommitdiff
path: root/pom.xml
diff options
context:
space:
mode:
authorSean Owen <sowen@cloudera.com>2014-05-12 14:16:19 -0700
committerPatrick Wendell <pwendell@gmail.com>2014-05-12 14:16:33 -0700
commit14515b416e9a00cb3a77c2645984265b30b05882 (patch)
tree09bb1756961915015ed9b64ccc3e27199ea13343 /pom.xml
parent722ecaa0195674be1b69c2f0a50fe21f3cf62ffc (diff)
downloadspark-14515b416e9a00cb3a77c2645984265b30b05882.tar.gz
spark-14515b416e9a00cb3a77c2645984265b30b05882.tar.bz2
spark-14515b416e9a00cb3a77c2645984265b30b05882.zip
SPARK-1798. Tests should clean up temp files
Three issues related to temp files that tests generate – these should be touched up for hygiene but are not urgent. Modules have a log4j.properties which directs the unit-test.log output file to a directory like `[module]/target/unit-test.log`. But this ends up creating `[module]/[module]/target/unit-test.log` instead of former. The `work/` directory is not deleted by "mvn clean", in the parent and in modules. Neither is the `checkpoint/` directory created under the various external modules. Many tests create a temp directory, which is not usually deleted. This can be largely resolved by calling `deleteOnExit()` at creation and trying to call `Utils.deleteRecursively` consistently to clean up, sometimes in an `@After` method. _If anyone seconds the motion, I can create a more significant change that introduces a new test trait along the lines of `LocalSparkContext`, which provides management of temp directories for subclasses to take advantage of._ Author: Sean Owen <sowen@cloudera.com> Closes #732 from srowen/SPARK-1798 and squashes the following commits: 5af578e [Sean Owen] Try to consistently delete test temp dirs and files, and set deleteOnExit() for each b21b356 [Sean Owen] Remove work/ and checkpoint/ dirs with mvn clean bdd0f41 [Sean Owen] Remove duplicate module dir in log4j.properties output path for tests (cherry picked from commit 7120a2979d0a9f0f54a88b2416be7ca10e74f409) Signed-off-by: Patrick Wendell <pwendell@gmail.com>
Diffstat (limited to 'pom.xml')
-rw-r--r--pom.xml15
1 files changed, 15 insertions, 0 deletions
diff --git a/pom.xml b/pom.xml
index 5b18266266..e8157c3d2e 100644
--- a/pom.xml
+++ b/pom.xml
@@ -796,6 +796,21 @@
</execution>
</executions>
</plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-clean-plugin</artifactId>
+ <version>2.5</version>
+ <configuration>
+ <filesets>
+ <fileset>
+ <directory>work</directory>
+ </fileset>
+ <fileset>
+ <directory>checkpoint</directory>
+ </fileset>
+ </filesets>
+ </configuration>
+ </plugin>
</plugins>
</pluginManagement>