Skip to content

Commit

Permalink
searchfilters: Test: adjust MediaCCC tests
Browse files Browse the repository at this point in the history
  • Loading branch information
evermind-zz committed Oct 11, 2022
1 parent 97c9b60 commit 05a6abe
Showing 1 changed file with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@
import org.schabi.newpipe.extractor.StreamingService;
import org.schabi.newpipe.extractor.search.SearchExtractor;
import org.schabi.newpipe.extractor.services.DefaultSearchExtractorTest;
import org.schabi.newpipe.extractor.services.media_ccc.search.filter.MediaCCCFilters;


import javax.annotation.Nullable;

import static java.util.Collections.singletonList;
import static org.schabi.newpipe.extractor.ServiceList.MediaCCC;
import static org.schabi.newpipe.extractor.services.media_ccc.linkHandler.MediaCCCSearchQueryHandlerFactory.CONFERENCES;
import static org.schabi.newpipe.extractor.services.media_ccc.linkHandler.MediaCCCSearchQueryHandlerFactory.EVENTS;

public class MediaCCCSearchExtractorTest {
public static class All extends DefaultSearchExtractorTest {
Expand Down Expand Up @@ -46,7 +46,8 @@ public static class Conferences extends DefaultSearchExtractorTest {
@BeforeAll
public static void setUp() throws Exception {
NewPipe.init(DownloaderTestImpl.getInstance());
extractor = MediaCCC.getSearchExtractor(QUERY, singletonList(CONFERENCES), "");
extractor = MediaCCC.getSearchExtractor(QUERY, singletonList(
getFilterItem(MediaCCC, MediaCCCFilters.ID_CF_MAIN_CONFERENCES)), null);
extractor.fetchPage();
}

Expand All @@ -70,7 +71,8 @@ public static class Events extends DefaultSearchExtractorTest {
@BeforeAll
public static void setUp() throws Exception {
NewPipe.init(DownloaderTestImpl.getInstance());
extractor = MediaCCC.getSearchExtractor(QUERY, singletonList(EVENTS), "");
extractor = MediaCCC.getSearchExtractor(QUERY, singletonList(
getFilterItem(MediaCCC, MediaCCCFilters.ID_CF_MAIN_EVENTS)), null);
extractor.fetchPage();
}

Expand Down

0 comments on commit 05a6abe

Please sign in to comment.