mirror of https://github.com/apache/activemq.git
these tests were failing on windows where File.delete fails if the file is still open.
git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@387663 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
8866e28fbc
commit
261b455078
|
@ -1,15 +1,11 @@
|
|||
package org.apache.activemq.kaha;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.HashMap;
|
||||
import java.util.Iterator;
|
||||
import java.util.LinkedList;
|
||||
import java.util.List;
|
||||
import java.util.ListIterator;
|
||||
import java.util.Map;
|
||||
import org.apache.activemq.kaha.ListContainer;
|
||||
import org.apache.activemq.kaha.Store;
|
||||
import org.apache.activemq.kaha.StoreFactory;
|
||||
|
||||
import junit.framework.TestCase;
|
||||
|
||||
public class ListContainerTest extends TestCase{
|
||||
|
@ -310,6 +306,9 @@ public class ListContainerTest extends TestCase{
|
|||
|
||||
protected void tearDown() throws Exception{
|
||||
super.tearDown();
|
||||
if( store!= null ) {
|
||||
store.close();
|
||||
}
|
||||
assertTrue(StoreFactory.delete(name));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -173,6 +173,10 @@ public class MapContainerTest extends TestCase{
|
|||
|
||||
protected void tearDown() throws Exception{
|
||||
super.tearDown();
|
||||
if( store != null ) {
|
||||
store.close();
|
||||
store=null;
|
||||
}
|
||||
assertTrue(StoreFactory.delete(name));
|
||||
}
|
||||
|
||||
|
|
|
@ -203,6 +203,11 @@ public class StoreTest extends TestCase{
|
|||
|
||||
protected void tearDown() throws Exception{
|
||||
super.tearDown();
|
||||
assertTrue(StoreFactory.delete(name));
|
||||
if( store!=null ) {
|
||||
store.close();
|
||||
store=null;
|
||||
}
|
||||
boolean rc = StoreFactory.delete(name);
|
||||
assertTrue(rc);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue