mirror of
https://github.com/TeamNewPipe/NewPipeExtractor.git
synced 2025-04-28 16:00:33 +05:30
Merge pull request #1105 from TeamNewPipe/fix/bandcamp-streame-extractor-test
[Badcamp] Fix StreamExtractorTest
This commit is contained in:
commit
90aed06a63
@ -34,7 +34,7 @@ public class BandcampStreamExtractorTest extends DefaultStreamExtractorTest {
|
|||||||
NewPipe.init(DownloaderTestImpl.getInstance());
|
NewPipe.init(DownloaderTestImpl.getInstance());
|
||||||
|
|
||||||
extractor = (BandcampStreamExtractor) Bandcamp
|
extractor = (BandcampStreamExtractor) Bandcamp
|
||||||
.getStreamExtractor("https://teaganbear.bandcamp.com/track/just-for-the-halibut-creative-commons-attribution");
|
.getStreamExtractor("https://teaganbear.bandcamp.com/track/just-for-the-halibut");
|
||||||
extractor.fetchPage();
|
extractor.fetchPage();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -50,22 +50,22 @@ public class BandcampStreamExtractorTest extends DefaultStreamExtractorTest {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String expectedName() {
|
public String expectedName() {
|
||||||
return "Just for the Halibut [Creative Commons: Attribution]";
|
return "Just for the Halibut";
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String expectedId() {
|
public String expectedId() {
|
||||||
return "https://teaganbear.bandcamp.com/track/just-for-the-halibut-creative-commons-attribution";
|
return "https://teaganbear.bandcamp.com/track/just-for-the-halibut";
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String expectedUrlContains() {
|
public String expectedUrlContains() {
|
||||||
return "https://teaganbear.bandcamp.com/track/just-for-the-halibut-creative-commons-attribution";
|
return "https://teaganbear.bandcamp.com/track/just-for-the-halibut";
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String expectedOriginalUrlContains() {
|
public String expectedOriginalUrlContains() {
|
||||||
return "https://teaganbear.bandcamp.com/track/just-for-the-halibut-creative-commons-attribution";
|
return "https://teaganbear.bandcamp.com/track/just-for-the-halibut";
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -157,7 +157,7 @@ public class BandcampStreamExtractorTest extends DefaultStreamExtractorTest {
|
|||||||
void testTranslateIdsToUrl() throws ParsingException {
|
void testTranslateIdsToUrl() throws ParsingException {
|
||||||
// To add tests: look at website's source, search for `band_id` and `item_id`
|
// To add tests: look at website's source, search for `band_id` and `item_id`
|
||||||
assertEquals(
|
assertEquals(
|
||||||
"https://teaganbear.bandcamp.com/track/just-for-the-halibut-creative-commons-attribution",
|
"https://teaganbear.bandcamp.com/track/just-for-the-halibut",
|
||||||
BandcampExtractorHelper.getStreamUrlFromIds(3877364987L, 3486455278L, "track")
|
BandcampExtractorHelper.getStreamUrlFromIds(3877364987L, 3486455278L, "track")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user