Search in sources :

Example 11 with Comment

use of org.ambraproject.rhino.model.Comment in project rhino by PLOS.

the class CommentOutputViewTest method init.

@BeforeMethod
public void init() {
    when(runtimeConfiguration.getCompetingInterestPolicyStart()).thenReturn(LocalDate.now(ZoneId.systemDefault()));
    Comment comment = createStubComment();
    factory = new CommentOutputView.Factory(new CompetingInterestPolicy(runtimeConfiguration), ImmutableList.of(comment), comment.getArticle());
}
Also used : Comment(org.ambraproject.rhino.model.Comment) BeforeMethod(org.testng.annotations.BeforeMethod)

Aggregations

Comment (org.ambraproject.rhino.model.Comment)11 Article (org.ambraproject.rhino.model.Article)4 RestClientException (org.ambraproject.rhino.rest.RestClientException)4 Flag (org.ambraproject.rhino.model.Flag)3 CommentOutputView (org.ambraproject.rhino.view.comment.CommentOutputView)3 CompetingInterestPolicy (org.ambraproject.rhino.view.comment.CompetingInterestPolicy)3 UUID (java.util.UUID)2 ArticleIdentifier (org.ambraproject.rhino.identity.ArticleIdentifier)2 Doi (org.ambraproject.rhino.identity.Doi)2 Journal (org.ambraproject.rhino.model.Journal)2 CommentNodeView (org.ambraproject.rhino.view.comment.CommentNodeView)2 Query (org.hibernate.Query)2 Preconditions (com.google.common.base.Preconditions)1 Strings (com.google.common.base.Strings)1 ImmutableList (com.google.common.collect.ImmutableList)1 IOException (java.io.IOException)1 LocalDate (java.time.LocalDate)1 Collection (java.util.Collection)1 List (java.util.List)1 Optional (java.util.Optional)1