File tree Expand file tree Collapse file tree 1 file changed +3
-10
lines changed
src/test/java/eatda/service/article Expand file tree Collapse file tree 1 file changed +3
-10
lines changed Original file line number Diff line number Diff line change 44
55import eatda .controller .article .ArticleResponse ;
66import eatda .service .BaseServiceTest ;
7- import java .util .List ;
87import java .util .stream .LongStream ;
98import org .junit .jupiter .api .Nested ;
109import org .junit .jupiter .api .Test ;
@@ -25,15 +24,9 @@ class GetAllArticles {
2524
2625 var response = articleService .getAllArticles (3 );
2726
28- assertThat (response .articles ()).hasSize (3 );
29- List <String > titles = response .articles ().stream ()
30- .map (ArticleResponse ::title )
31- .toList ();
32- assertThat (titles ).containsExactly (
33- "아티클 제목 5" ,
34- "아티클 제목 4" ,
35- "아티클 제목 3"
36- );
27+ assertThat (response .articles ()).hasSize (3 )
28+ .extracting (ArticleResponse ::title )
29+ .containsExactly ("아티클 제목 5" , "아티클 제목 4" , "아티클 제목 3" );
3730 }
3831 }
3932}
You can’t perform that action at this time.
0 commit comments