Changed classes signature

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/private/luca.frosini/infrastructure-tests@133110 82a268e6-3cf1-43bd-a215-b396298e98cf
master
Luca Frosini 8 years ago
parent fe6c2a0609
commit 06ed89289c

@ -74,7 +74,7 @@
<dependency>
<groupId>org.gcube.common</groupId>
<artifactId>couchdb-connector</artifactId>
<version>[1.0.0-SNAPSHOT, 2.0.0-SNAPSHOT)</version>
<version>[2.0.0-SNAPSHOT, 3.0.0-SNAPSHOT)</version>
<scope>test</scope>
</dependency>
<dependency>

@ -12,7 +12,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class AccountingPersistenceQueryConfigurationTest extends ScopedTest {

@ -32,7 +32,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class AccountingPersistenceQueryFactoryTest extends ScopedTest {

@ -24,7 +24,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class AccountingPersistenceQueryCouchBaseTest extends ScopedTest {

@ -26,7 +26,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class AccountingPersistenceQueryCouchDBTest extends ScopedTest {

@ -13,7 +13,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class DeleteTestDocument extends ScopedTest {

@ -20,7 +20,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*/
public class CouchDBQueryPluginSmartExecutorSchedulerTest extends ScopedTest {

@ -10,7 +10,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*/
public class CouchDBQueryPluginTest extends ScopedTest {

@ -19,7 +19,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class RecordUtilityTest {

@ -22,7 +22,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class AccountingTest {

@ -14,7 +14,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class JobUsageRecordScopedTest extends ScopedTest {

@ -14,7 +14,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class ServiceUsageRecordScopedTest extends ScopedTest {

@ -14,7 +14,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class StorageUsageRecordScopedTest extends ScopedTest {

@ -22,7 +22,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class TaskUsageRecordScopedTest extends ScopedTest {

@ -22,7 +22,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class AccountingPersistenceConfigurationTest extends ScopedTest {

@ -25,7 +25,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class PersistenceCouchBaseTest extends ScopedTest {

@ -24,7 +24,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class PersistenceCouchDBTest extends ScopedTest {

@ -23,7 +23,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class PersistenceMongoDBTest extends ScopedTest {

@ -10,7 +10,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class PersistenceBackendFactoryTest {

@ -17,7 +17,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class PersistenceBackendMonitorTest extends ScopedTest {

@ -19,7 +19,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class PersistenceBackendTest extends ScopedTest {

@ -20,7 +20,7 @@ import org.slf4j.LoggerFactory;
import com.couchbase.client.deps.com.fasterxml.jackson.databind.JsonNode;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class PersistenceCouchBaseTest extends ScopedTest {

@ -15,7 +15,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class PersistenceCouchDBTest extends ScopedTest {

@ -16,7 +16,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class PersistenceMongoDBTest {

@ -17,7 +17,7 @@ import org.gcube.testutility.TestUsageRecord;
import org.junit.Test;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class RenameFileTest extends ScopedTest {

@ -18,7 +18,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class RecordUtilityTest {

@ -22,7 +22,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class AggregationSchedulerTest extends ScopedTest {

@ -21,9 +21,9 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*/
public class SocialDataIndexerPluginSmartExecutorSchedulerTest extends ScopedTest {
public class SocialDataIndexerPluginSmartExecutorSchedulerTest {
private static Logger logger = LoggerFactory.getLogger(SocialDataIndexerPluginSmartExecutorSchedulerTest.class);
@ -31,7 +31,7 @@ public class SocialDataIndexerPluginSmartExecutorSchedulerTest extends ScopedTes
@Before
public void before() throws Exception{
super.before();
//super.before();
//ScopeProvider.instance.reset(); // Comment this to run the test. this line has been added to avoid unwanted launch
ScopeProvider.instance.set("/gcube");
proxy = ExecutorPlugin.getExecutorProxy("social-data-indexer-plugin").build();
@ -41,10 +41,11 @@ public class SocialDataIndexerPluginSmartExecutorSchedulerTest extends ScopedTes
public UUID scheduleTest(Scheduling scheduling, Long sleepTime) throws Exception {
Map<String, Object> inputs = new HashMap<String, Object>();
logger.debug("Inputs : {}", inputs);
inputs.put("scope", "gcube");
LaunchParameter parameter = new LaunchParameter("social-data-indexer-plugin", inputs);
parameter.setScheduling(scheduling);
try {
String uuidString = proxy.launch(parameter);
return UUID.fromString(uuidString);

@ -20,7 +20,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*/
public class ISSweeperPluginSmartExecutorSchedulerTest extends ScopedTest {

@ -9,7 +9,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*/
public class ISSweeperPluginTest extends ScopedTest {

@ -17,7 +17,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class RemoveGoodRITest extends ScopedTest {

@ -10,7 +10,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class AccountingTest extends ScopedTest {

@ -20,7 +20,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class TempTest {

@ -3,14 +3,13 @@
*/
package org.gcube.testutility;
//import org.gcube.common.authorization.library.provider.SecurityTokenProvider;
import org.gcube.common.authorization.library.provider.SecurityTokenProvider;
import org.gcube.common.scope.api.ScopeProvider;
import org.junit.After;
import org.junit.Before;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class ScopedTest {

@ -11,7 +11,7 @@ import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class StressTestUtility {

@ -5,7 +5,7 @@ package org.gcube.testutility;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public interface TestOperation {

@ -22,7 +22,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class TestUsageRecord {

@ -18,7 +18,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class TestUtility {

@ -12,7 +12,7 @@ import org.gcube.common.authorization.library.provider.SecurityTokenProvider;
import org.gcube.testutility.ScopedTest;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class GCoreEndPointCreationTest extends ScopedTest {

@ -26,7 +26,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class DefaultExecutorTest extends ScopedTest {
@ -110,8 +110,9 @@ public class DefaultExecutorTest extends ScopedTest {
inputs.put("Hello", "World");
long sleepTime = 20000; // 1000 millisec * 20 = 20 sec
inputs.put(HelloWorldPlugin.SLEEP_TIME, sleepTime);
int minuteinterval = 2;
// Every 5 minutes, for 12 times (one hour totally).
Scheduling scheduling = new Scheduling(60*5,12,true);
Scheduling scheduling = new Scheduling(60*minuteinterval,12,true);
scheduling.setGlobal(false);
LaunchParameter launchParameter = new LaunchParameter(HelloWorldPluginDeclaration.NAME, inputs, scheduling);
@ -130,12 +131,12 @@ public class DefaultExecutorTest extends ScopedTest {
Thread.sleep(6000); // 12 sec (total : 22 sec)
Assert.assertEquals(PluginState.DONE, proxy.getStateEvolution(executionIdentifier).getPluginState());
Thread.sleep(1000*60*5); // After 5 minutes the thread should be active again
Thread.sleep(1000*60*minuteinterval); // After 5 minutes the thread should be active again
Assert.assertEquals(PluginState.RUNNING, proxy.getStateEvolution(executionIdentifier).getPluginState());
Assert.assertEquals(PluginState.RUNNING, proxy.getIterationStateEvolution(executionIdentifier, 1).getPluginState());
logger.debug("Trying to stop scheduled task");
proxy.unSchedule(executionIdentifier, true);
//logger.debug("Trying to stop scheduled task");
//proxy.unSchedule(executionIdentifier, true);
} catch (Exception e) {
logger.error("testOk Exception", e);

@ -30,7 +30,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class QueriedClientTest {

@ -18,7 +18,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class SmartGenericWorkerDiscoveryQuery {

Loading…
Cancel
Save