]> source.dussan.org Git - sonarqube.git/commitdiff
fix unit test
authorTeryk Bellahsene <teryk.bellahsene@sonarsource.com>
Tue, 10 Feb 2015 13:55:22 +0000 (14:55 +0100)
committerTeryk Bellahsene <teryk.bellahsene@sonarsource.com>
Tue, 10 Feb 2015 13:55:22 +0000 (14:55 +0100)
server/sonar-server/src/test/java/org/sonar/server/issue/actionplan/ActionPlanServiceTest.java

index be974819dc63d743b40b9bdcd012030f1b157277..5e3459e82d1ca07974b0ff1fde3faa2283085718 100644 (file)
@@ -51,6 +51,7 @@ import org.sonar.server.user.MockUserSession;
 import org.sonar.server.user.UserSession;
 
 import java.util.Collection;
+import java.util.Date;
 
 import static com.google.common.collect.Lists.newArrayList;
 import static org.assertj.core.api.Assertions.assertThat;
@@ -158,7 +159,7 @@ public class ActionPlanServiceTest {
     when(actionPlanDao.findByKey("ABCD")).thenReturn(new ActionPlanDto().setKey("ABCD").setProjectKey_unit_test_only(projectKey));
     when(resourceDao.getResource(any(ResourceQuery.class))).thenReturn(new ResourceDto().setKey(projectKey).setId(1l));
 
-    IssueDto issueDto = new IssueDto().setId(100L).setStatus(Issue.STATUS_OPEN).setRuleKey("squid", "s100");
+    IssueDto issueDto = new IssueDto().setId(100L).setStatus(Issue.STATUS_OPEN).setRuleKey("squid", "s100").setIssueCreationDate(new Date());
     when(issueDao.findByActionPlan(session, "ABCD")).thenReturn(newArrayList(issueDto));
     when(issueUpdater.plan(any(DefaultIssue.class), eq((ActionPlan) null), any(IssueChangeContext.class))).thenReturn(true);