fix missed awaits for db.prepare in test cases

This commit is contained in:
mini-bomba
2025-09-10 23:24:44 +02:00
parent c942eea640
commit 5664ff4f58
9 changed files with 36 additions and 36 deletions

View File

@@ -19,8 +19,8 @@ describe("postSkipSegments - shadowban", () => {
const queryDatabaseShadowhidden = (videoID: string) => db.prepare("get", `SELECT "startTime", "endTime", "shadowHidden", "userID" FROM "sponsorTimes" WHERE "videoID" = ?`, [videoID]);
before(() => {
db.prepare("run", `INSERT INTO "shadowBannedUsers" ("userID") VALUES(?)`, [banUser01Hash]);
before(async () => {
await db.prepare("run", `INSERT INTO "shadowBannedUsers" ("userID") VALUES(?)`, [banUser01Hash]);
});
it("Should automatically shadowban segments if user is banned", (done) => {
@@ -65,4 +65,4 @@ describe("postSkipSegments - shadowban", () => {
})
.catch(err => done(err));
});
});
});