mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-13 15:06:59 +03:00
add test case
This commit is contained in:
@@ -987,4 +987,16 @@ describe("postSkipSegments", () => {
|
|||||||
})
|
})
|
||||||
.catch(err => done(err));
|
.catch(err => done(err));
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it("Should be rejected if a POI is at less than 1 second", (done: Done) => {
|
||||||
|
fetch(`${getbaseURL()
|
||||||
|
}/api/skipSegments?videoID=qqwerty&startTime=0.5&endTime=0.5&userID=testtesttesttesttesttesttesttesttesting`, {
|
||||||
|
method: "POST",
|
||||||
|
})
|
||||||
|
.then(res => {
|
||||||
|
assert.strictEqual(res.status, 400);
|
||||||
|
done();
|
||||||
|
})
|
||||||
|
.catch(err => done(err));
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user