archiva-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sk...@apache.org
Subject svn commit: r1381789 - /archiva/trunk/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/java/org/apache/archiva/rest/services/AbstractArchivaRestTest.java
Date Thu, 06 Sep 2012 22:31:47 GMT
Author: skygo
Date: Thu Sep  6 22:31:46 2012
New Revision: 1381789

URL: http://svn.apache.org/viewvc?rev=1381789&view=rev
Log:
remove conf and data file for Rest Test and jdk7

Modified:
    archiva/trunk/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/java/org/apache/archiva/rest/services/AbstractArchivaRestTest.java

Modified: archiva/trunk/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/java/org/apache/archiva/rest/services/AbstractArchivaRestTest.java
URL: http://svn.apache.org/viewvc/archiva/trunk/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/java/org/apache/archiva/rest/services/AbstractArchivaRestTest.java?rev=1381789&r1=1381788&r2=1381789&view=diff
==============================================================================
--- archiva/trunk/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/java/org/apache/archiva/rest/services/AbstractArchivaRestTest.java
(original)
+++ archiva/trunk/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/java/org/apache/archiva/rest/services/AbstractArchivaRestTest.java
Thu Sep  6 22:31:46 2012
@@ -87,16 +87,24 @@ public abstract class AbstractArchivaRes
     {        
         File appServerBase = new File( System.getProperty( "appserver.base" ) );
 
-        File jcrDirectory = new File( appServerBase, "jcr" );
+        removeAppsubFolder( appServerBase, "jcr" );
+        removeAppsubFolder( appServerBase, "conf" );
+        removeAppsubFolder( appServerBase, "data" );
         
-        if ( jcrDirectory.exists() )
+        
+        super.startServer();        
+    }
+    
+    private void removeAppsubFolder( File appServerBase, String folder )
+       throws Exception
+    {
+        File directory = new File( appServerBase, folder );        
+        if ( directory.exists() )
         {
-            FileUtils.deleteDirectory( jcrDirectory );
+            FileUtils.deleteDirectory( directory );
         }
-
-        super.startServer();        
     }
-
+    
     @Override
     protected String getSpringConfigLocation()
     {



Mime
View raw message