cleanup archivaConfiguration before new test

git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1136005 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Olivier Lamy 2011-06-15 11:54:15 +00:00
parent 1af82ff7d8
commit 26665cb8ea
2 changed files with 9 additions and 1 deletions

View File

@ -29,6 +29,10 @@
<artifactId>archiva-webdav</artifactId> <artifactId>archiva-webdav</artifactId>
<name>Archiva Web :: WebDAV</name> <name>Archiva Web :: WebDAV</name>
<properties>
<webdav.forkMode>always</webdav.forkMode>
</properties>
<dependencies> <dependencies>
<!-- TODO: remove this hardcoding through a better event mechanism --> <!-- TODO: remove this hardcoding through a better event mechanism -->
<dependency> <dependency>
@ -159,7 +163,7 @@
<systemPropertyVariables> <systemPropertyVariables>
<appserver.base>${basedir}/target/appserver-base</appserver.base> <appserver.base>${basedir}/target/appserver-base</appserver.base>
</systemPropertyVariables> </systemPropertyVariables>
<forkMode>always</forkMode> <forkMode>${webdav.forkMode}</forkMode>
</configuration> </configuration>
</plugin> </plugin>
</plugins> </plugins>

View File

@ -24,10 +24,12 @@ import com.meterware.httpunit.HttpUnitOptions;
import com.meterware.httpunit.WebRequest; import com.meterware.httpunit.WebRequest;
import com.meterware.httpunit.WebResponse; import com.meterware.httpunit.WebResponse;
import org.apache.maven.archiva.configuration.ProxyConnectorConfiguration;
import org.apache.maven.archiva.policies.SnapshotsPolicy; import org.apache.maven.archiva.policies.SnapshotsPolicy;
import org.junit.Test; import org.junit.Test;
import java.io.File; import java.io.File;
import java.util.ArrayList;
/** /**
* RepositoryServlet Tests, Proxied, Get of Timestamped Snapshot Artifacts, with varying policy settings. * RepositoryServlet Tests, Proxied, Get of Timestamped Snapshot Artifacts, with varying policy settings.
@ -178,6 +180,8 @@ public class RepositoryServletProxiedPluginSnapshotPolicyTest
managedFile.setLastModified( remoteFile.lastModified() + deltaManagedToRemoteTimestamp ); managedFile.setLastModified( remoteFile.lastModified() + deltaManagedToRemoteTimestamp );
} }
archivaConfiguration.getConfiguration().setProxyConnectors( new ArrayList<ProxyConnectorConfiguration>( 0 ) );
setupSnapshotConnector( REPOID_INTERNAL, remoteSnapshots, snapshotsPolicy ); setupSnapshotConnector( REPOID_INTERNAL, remoteSnapshots, snapshotsPolicy );
saveConfiguration(); saveConfiguration();