From c6e7ad3077eba0ccb6d117d196a16142370c5e91 Mon Sep 17 00:00:00 2001 From: "luca.frosini" Date: Mon, 18 Jun 2018 13:44:10 +0000 Subject: [PATCH] Fixed test to harvest old data for VREAccessesHarvester git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/accounting/accounting-dashboard-harvester-se-plugin@169298 82a268e6-3cf1-43bd-a215-b396298e98cf --- .../gcube/dataharvest/AccountingDataHarvesterPluginTest.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/test/java/org/gcube/dataharvest/AccountingDataHarvesterPluginTest.java b/src/test/java/org/gcube/dataharvest/AccountingDataHarvesterPluginTest.java index 0e34a05..858e9ad 100644 --- a/src/test/java/org/gcube/dataharvest/AccountingDataHarvesterPluginTest.java +++ b/src/test/java/org/gcube/dataharvest/AccountingDataHarvesterPluginTest.java @@ -10,6 +10,7 @@ import java.util.Map; import java.util.Properties; import java.util.SortedSet; import java.util.TreeSet; +import java.util.concurrent.TimeUnit; import org.gcube.common.scope.impl.ScopeBean; import org.gcube.common.scope.impl.ScopeBean.Type; @@ -146,7 +147,7 @@ public class AccountingDataHarvesterPluginTest extends ContextTest { AggregationType aggregationType = AggregationType.MONTHLY; - Calendar from = DateUtils.getStartCalendar(2016, Calendar.SEPTEMBER, 1); + Calendar from = DateUtils.getStartCalendar(2018, Calendar.APRIL, 1); Calendar runbeforeDate = DateUtils.getStartCalendar(2018, Calendar.JUNE, 1); @@ -206,6 +207,8 @@ public class AccountingDataHarvesterPluginTest extends ContextTest { Utils.setContext(ROOT); dbaseManager.insertMonthlyData(start, end, data, true); + Thread.sleep(TimeUnit.SECONDS.toMillis(10)); + from.add(aggregationType.getCalendarField(), 1); }