88
99import static org .junit .jupiter .api .Assertions .assertEquals ;
1010import static org .junit .jupiter .api .Assertions .assertTrue ;
11+ import static org .schabi .newpipe .extractor .ExtractorAsserts .assertContainsImageUrlInImageCollection ;
1112import static org .schabi .newpipe .extractor .ServiceList .MediaCCC ;
1213
1314/**
@@ -25,27 +26,29 @@ public static void setUpClass() throws Exception {
2526 }
2627
2728 @ Test
28- public void testName () throws Exception {
29+ void testName () throws Exception {
2930 assertEquals ("FrOSCon 2017" , extractor .getName ());
3031 }
3132
3233 @ Test
33- public void testGetUrl () throws Exception {
34+ void testGetUrl () throws Exception {
3435 assertEquals ("https://media.ccc.de/c/froscon2017" , extractor .getUrl ());
3536 }
3637
3738 @ Test
38- public void testGetOriginalUrl () throws Exception {
39+ void testGetOriginalUrl () throws Exception {
3940 assertEquals ("https://media.ccc.de/c/froscon2017" , extractor .getOriginalUrl ());
4041 }
4142
4243 @ Test
43- public void testGetThumbnailUrl () throws Exception {
44- assertEquals ("https://static.media.ccc.de/media/events/froscon/2017/logo.png" , extractor .getAvatarUrl ());
44+ void testGetThumbnails () {
45+ assertContainsImageUrlInImageCollection (
46+ "https://static.media.ccc.de/media/events/froscon/2017/logo.png" ,
47+ extractor .getAvatars ());
4548 }
4649
4750 @ Test
48- public void testGetInitalPage () throws Exception {
51+ void testGetInitalPage () {
4952 assertEquals (97 , extractor .getInitialPage ().getItems ().size ());
5053 }
5154 }
@@ -61,27 +64,29 @@ public static void setUpClass() throws Exception {
6164 }
6265
6366 @ Test
64- public void testName () throws Exception {
67+ void testName () throws Exception {
6568 assertEquals ("Open Source Conference Albania 2019" , extractor .getName ());
6669 }
6770
6871 @ Test
69- public void testGetUrl () throws Exception {
72+ void testGetUrl () throws Exception {
7073 assertEquals ("https://media.ccc.de/c/oscal19" , extractor .getUrl ());
7174 }
7275
7376 @ Test
74- public void testGetOriginalUrl () throws Exception {
77+ void testGetOriginalUrl () throws Exception {
7578 assertEquals ("https://media.ccc.de/c/oscal19" , extractor .getOriginalUrl ());
7679 }
7780
7881 @ Test
79- public void testGetThumbnailUrl () throws Exception {
80- assertEquals ("https://static.media.ccc.de/media/events/oscal/2019/oscal-19.png" , extractor .getAvatarUrl ());
82+ void testGetThumbnailUrl () {
83+ assertContainsImageUrlInImageCollection (
84+ "https://static.media.ccc.de/media/events/oscal/2019/oscal-19.png" ,
85+ extractor .getAvatars ());
8186 }
8287
8388 @ Test
84- public void testGetInitalPage () throws Exception {
89+ void testGetInitalPage () {
8590 assertTrue (extractor .getInitialPage ().getItems ().size () >= 21 );
8691 }
8792 }
0 commit comments