mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-06 11:36:58 +03:00
reverted test to 404
This commit is contained in:
@@ -40,16 +40,15 @@ describe('getSegmentsByHash', () => {
|
||||
});
|
||||
});
|
||||
|
||||
it('Should be able to get an emptry array if no videos', (done) => {
|
||||
it('Should be able to get an empty array if no videos', (done) => {
|
||||
request.get(utils.getbaseURL()
|
||||
+ '/api/skipSegments/11111?categories=["shilling"]', null,
|
||||
(err, res, body) => {
|
||||
if (err) done("Couldn't call endpoint");
|
||||
else if (res.statusCode !== 200) done("non 200 status code, was " + res.statusCode);
|
||||
else if (res.statusCode !== 404) done("non 404 status code, was " + res.statusCode);
|
||||
else {
|
||||
if (JSON.parse(body).length === 0) done(); // pass
|
||||
if (JSON.parse(body).length === 0 && body === '[]') done(); // pass
|
||||
else done("non empty array returned");
|
||||
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user