Improve code for YouTube Music search

This commit is contained in:
wb9688
2020-03-20 19:14:53 +01:00
parent dc29d87962
commit d58c0f230d
2 changed files with 38 additions and 12 deletions

View File

@@ -19,6 +19,7 @@ import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;
import static org.schabi.newpipe.extractor.ServiceList.YouTube;
import static org.schabi.newpipe.extractor.services.DefaultTests.defaultTestRelatedItems;
public class YoutubeSearchExtractorMusicTest extends YoutubeSearchExtractorBaseTest {
@BeforeClass
@@ -30,6 +31,11 @@ public class YoutubeSearchExtractorMusicTest extends YoutubeSearchExtractorBaseT
itemsPage = extractor.getInitialPage();
}
@Test
public void testRelatedItems() throws Exception {
defaultTestRelatedItems(extractor);
}
@Test
public void testGetSecondPage() throws Exception {
YoutubeSearchExtractor secondExtractor = (YoutubeSearchExtractor) YouTube.getSearchExtractor("mocromaniac",