Пример #1
0
 @Test
 public void findRepostByTweets_String_単数_投稿者_00() {
   Account acnt = Account.findByLoginName("goro_san").first();
   List<RepostBase> lst = RepostBase.findRepostByTweets("twt-goro2").contributor(acnt).fetch();
   assertThat(lst.size(), is(2));
   // DBからの取得リストの並び保証なし
 }
Пример #2
0
 // -------------------------------------+
 @Test
 public void findRepostByTweets_Entity_単数_00() {
   Tweet twt1 = Tweet.findBySerialCode("twt-goro2").first();
   List<RepostBase> lst = RepostBase.findRepostByTweets(twt1).fetch();
   assertThat(lst.size(), is(4));
   // DBからの取得リストの並び保証なし
 }
Пример #3
0
 @Test
 public void findRepostByTweets_Entity_複数_投稿者_00() {
   Tweet twt1 = Tweet.findBySerialCode("twt-goro2").first();
   Tweet twt2 = Tweet.findBySerialCode("twt-jiro1").first();
   Account acnt = Account.findByLoginName("goro_san").first();
   List<RepostBase> lst = RepostBase.findRepostByTweets(twt1, twt2).contributor(acnt).fetch();
   assertThat(lst.size(), is(5));
   // DBからの取得リストの並び保証なし
 }
Пример #4
0
 @Test
 public void findRepostByTweets_String_複数_投稿者_降順_00() {
   Account acnt = Account.findByLoginName("goro_san").first();
   List<RepostBase> lst =
       RepostBase.findRepostByTweets("twt-goro2", "twt-jiro1")
           .contributor(acnt)
           .orderBy(RepostBase.OrderBy.DATE_OF_REPOST_DESC)
           .fetch();
   assertThat(lst.size(), is(5));
   assertThat(lst.get(0).getItem().serialCode, is("twt-jiro1"));
 }
Пример #5
0
 @Test
 public void findRepostByTweets_String_複数_00() {
   List<RepostBase> lst = RepostBase.findRepostByTweets("twt-goro2", "twt-jiro1").fetch();
   assertThat(lst.size(), is(7));
   // DBからの取得リストの並び保証なし
 }
Пример #6
0
 // =============================================*
 // 問題なし
 @Test
 public void findRepostByTweets_例外_00() {
   List<RepostBase> lst = RepostBase.findRepostByTweets((Object) null).fetch();
   assertThat(lst.size(), is(23));
 }