mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2024-11-10 01:02:30 +01:00
Merge pull request #476 from mchangrh/fullvideo-revive-nonvip
add tests for #454
This commit is contained in:
commit
972cb96259
1 changed files with 13 additions and 0 deletions
|
@ -654,4 +654,17 @@ describe("voteOnSponsorTime", () => {
|
|||
done();
|
||||
});
|
||||
});
|
||||
|
||||
it("Should not be able to revive full video segment as non-vip", (done) => {
|
||||
const UUID = "full-video-uuid-1";
|
||||
postVote("VIPUser", UUID, 0); // downvote as VIP
|
||||
postVote("randomID3", UUID, 1)
|
||||
.then(async res => {
|
||||
assert.strictEqual(res.status, 200);
|
||||
const row = await getSegmentVotes(UUID);
|
||||
assert.strictEqual(row.votes, -2);
|
||||
done();
|
||||
})
|
||||
.catch(err => done(err));
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue