Skip to content

Commit 18846ba

Browse files
AudricVTheta-Dev
authored andcommitted
Add tabs and tags methods in tests interfaces and annotate all methods with the Test JUnit annotation
These changes should help to detect tests as tests, when running a subset of tests or all tests. They should be also implemented in these interfaces' implementations (new and existing ones). Co-authored-by: ThetaDev <t.testboy@gmail.com>
1 parent c70a0e3 commit 18846ba

6 files changed

Lines changed: 71 additions & 6 deletions

File tree

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,22 @@
11
package org.schabi.newpipe.extractor.services;
22

3-
@SuppressWarnings("unused")
4-
public interface BaseChannelExtractorTest extends BaseListExtractorTest {
3+
import org.junit.jupiter.api.Test;
4+
5+
public interface BaseChannelExtractorTest extends BaseExtractorTest {
6+
@Test
57
void testDescription() throws Exception;
8+
@Test
69
void testAvatarUrl() throws Exception;
10+
@Test
711
void testBannerUrl() throws Exception;
12+
@Test
813
void testFeedUrl() throws Exception;
14+
@Test
915
void testSubscriberCount() throws Exception;
16+
@Test
1017
void testVerified() throws Exception;
18+
@Test
19+
void testTabs() throws Exception;
20+
@Test
21+
void testTags() throws Exception;
1122
}
Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,16 @@
11
package org.schabi.newpipe.extractor.services;
22

3-
@SuppressWarnings("unused")
3+
import org.junit.jupiter.api.Test;
4+
45
public interface BaseExtractorTest {
6+
@Test
57
void testServiceId() throws Exception;
8+
@Test
69
void testName() throws Exception;
10+
@Test
711
void testId() throws Exception;
12+
@Test
813
void testUrl() throws Exception;
14+
@Test
915
void testOriginalUrl() throws Exception;
1016
}
Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
package org.schabi.newpipe.extractor.services;
22

3-
@SuppressWarnings("unused")
3+
import org.junit.jupiter.api.Test;
4+
45
public interface BaseListExtractorTest extends BaseExtractorTest {
6+
@Test
57
void testRelatedItems() throws Exception;
8+
@Test
69
void testMoreRelatedItems() throws Exception;
710
}
Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,18 @@
11
package org.schabi.newpipe.extractor.services;
22

3-
@SuppressWarnings("unused")
3+
import org.junit.jupiter.api.Test;
4+
45
public interface BasePlaylistExtractorTest extends BaseListExtractorTest {
6+
@Test
57
void testThumbnailUrl() throws Exception;
8+
@Test
69
void testBannerUrl() throws Exception;
10+
@Test
711
void testUploaderName() throws Exception;
12+
@Test
813
void testUploaderAvatarUrl() throws Exception;
14+
@Test
915
void testStreamCount() throws Exception;
16+
@Test
1017
void testUploaderVerified() throws Exception;
1118
}
Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,12 @@
11
package org.schabi.newpipe.extractor.services;
22

3-
@SuppressWarnings("unused")
3+
import org.junit.jupiter.api.Test;
4+
45
public interface BaseSearchExtractorTest extends BaseListExtractorTest {
6+
@Test
57
void testSearchString() throws Exception;
8+
@Test
69
void testSearchSuggestion() throws Exception;
10+
@Test
711
void testSearchCorrected() throws Exception;
812
}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,70 @@
11
package org.schabi.newpipe.extractor.services;
22

3+
import org.junit.jupiter.api.Test;
4+
35
public interface BaseStreamExtractorTest extends BaseExtractorTest {
6+
@Test
47
void testStreamType() throws Exception;
8+
@Test
59
void testUploaderName() throws Exception;
10+
@Test
611
void testUploaderUrl() throws Exception;
12+
@Test
713
void testUploaderAvatarUrl() throws Exception;
14+
@Test
815
void testSubscriberCount() throws Exception;
16+
@Test
917
void testSubChannelName() throws Exception;
18+
@Test
1019
void testSubChannelUrl() throws Exception;
20+
@Test
1121
void testSubChannelAvatarUrl() throws Exception;
22+
@Test
1223
void testThumbnailUrl() throws Exception;
24+
@Test
1325
void testDescription() throws Exception;
26+
@Test
1427
void testLength() throws Exception;
28+
@Test
1529
void testTimestamp() throws Exception;
30+
@Test
1631
void testViewCount() throws Exception;
32+
@Test
1733
void testUploadDate() throws Exception;
34+
@Test
1835
void testTextualUploadDate() throws Exception;
36+
@Test
1937
void testLikeCount() throws Exception;
38+
@Test
2039
void testDislikeCount() throws Exception;
40+
@Test
2141
void testRelatedItems() throws Exception;
42+
@Test
2243
void testAgeLimit() throws Exception;
44+
@Test
2345
void testErrorMessage() throws Exception;
46+
@Test
2447
void testAudioStreams() throws Exception;
48+
@Test
2549
void testVideoStreams() throws Exception;
50+
@Test
2651
void testSubtitles() throws Exception;
52+
@Test
2753
void testGetDashMpdUrl() throws Exception;
54+
@Test
2855
void testFrames() throws Exception;
56+
@Test
2957
void testHost() throws Exception;
58+
@Test
3059
void testPrivacy() throws Exception;
60+
@Test
3161
void testCategory() throws Exception;
62+
@Test
3263
void testLicence() throws Exception;
64+
@Test
3365
void testLanguageInfo() throws Exception;
66+
@Test
3467
void testTags() throws Exception;
68+
@Test
3569
void testSupportInfo() throws Exception;
3670
}

0 commit comments

Comments
 (0)