Search in sources :

Example 66 with AfterMethod

use of org.testng.annotations.AfterMethod in project elasticsearch-skywalker by jprante.

the class AbstractNodeTest method deleteIndices.

@AfterMethod
public void deleteIndices() {
    try {
        // clear test index
        client("1").admin().indices().delete(new DeleteIndexRequest().indices(INDEX)).actionGet();
    } catch (IndexMissingException e) {
    // ignore
    }
    closeNode("1");
    closeAllNodes();
}
Also used : DeleteIndexRequest(org.elasticsearch.action.admin.indices.delete.DeleteIndexRequest) IndexMissingException(org.elasticsearch.indices.IndexMissingException) AfterMethod(org.testng.annotations.AfterMethod)

Example 67 with AfterMethod

use of org.testng.annotations.AfterMethod in project otter by alibaba.

the class ExecIntegration method tearDown.

@AfterMethod
public void tearDown() {
    String tmp = System.getProperty("java.io.tmpdir", "/tmp");
    new File(tmp + "/exec.log").deleteOnExit();
}
Also used : File(java.io.File) AfterMethod(org.testng.annotations.AfterMethod)

Example 68 with AfterMethod

use of org.testng.annotations.AfterMethod in project JGroups by belaban.

the class ClusterSplitLockTest method tearDown.

@AfterMethod
protected void tearDown() throws Exception {
    Util.closeReverse(channels);
    Stream.of(execs).forEach(ExecutorService::shutdown);
    for (ExecutorService ex : execs) assertTrue(ex.awaitTermination(5, SECONDS));
}
Also used : ExecutorService(java.util.concurrent.ExecutorService) AfterMethod(org.testng.annotations.AfterMethod)

Example 69 with AfterMethod

use of org.testng.annotations.AfterMethod in project JGroups by belaban.

the class RSVPTest method tearDown.

@AfterMethod
void tearDown() throws Exception {
    for (int i = NUM - 1; i >= 0; i--) {
        ProtocolStack stack = channels[i].getProtocolStack();
        String cluster_name = channels[i].getClusterName();
        stack.stopStack(cluster_name);
        stack.destroy();
    }
}
Also used : ProtocolStack(org.jgroups.stack.ProtocolStack) AfterMethod(org.testng.annotations.AfterMethod)

Example 70 with AfterMethod

use of org.testng.annotations.AfterMethod in project JGroups by belaban.

the class MessageDispatcherRSVPTest method tearDown.

@AfterMethod
void tearDown() throws Exception {
    for (int i = NUM - 1; i >= 0; i--) {
        ProtocolStack stack = channels[i].getProtocolStack();
        String cluster_name = channels[i].getClusterName();
        stack.stopStack(cluster_name);
        stack.destroy();
    }
}
Also used : ProtocolStack(org.jgroups.stack.ProtocolStack) AfterMethod(org.testng.annotations.AfterMethod)

Aggregations

AfterMethod (org.testng.annotations.AfterMethod)74 File (java.io.File)16 MifosPage (org.mifos.test.acceptance.framework.MifosPage)10 DateTimeUpdaterRemoteTestingService (org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService)8 ProtocolStack (org.jgroups.stack.ProtocolStack)6 IOException (java.io.IOException)5 HashSet (java.util.HashSet)4 AtlasVertex (org.apache.atlas.repository.graphdb.AtlasVertex)4 Connection (java.sql.Connection)3 SQLException (java.sql.SQLException)3 MockParticipantManager (org.apache.helix.integration.manager.MockParticipantManager)3 JdbcSession (com.evolveum.midpoint.repo.sqlbase.JdbcSession)2 DispatchManager (com.facebook.presto.dispatcher.DispatchManager)2 OServerAdmin (com.orientechnologies.orient.client.remote.OServerAdmin)2 OStorageProxy (com.orientechnologies.orient.core.storage.OStorageProxy)2 RandomAccessFile (java.io.RandomAccessFile)2 Date (java.util.Date)2 ExecutorService (java.util.concurrent.ExecutorService)2 DeleteIndexRequest (org.elasticsearch.action.admin.indices.delete.DeleteIndexRequest)2 Parameters (org.testng.annotations.Parameters)2