Skip to content

Commit 38cb01d

Browse files
await commit and rollback
1 parent 029c73a commit 38cb01d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/tests/sqlite/rawQueries.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ export function registerBaseTests() {
157157

158158
await db.writeTransaction(async (tx) => {
159159
await tx.execute('INSERT INTO "User" (id, name, age, networth) VALUES(?, ?, ?, ?)', [id, name, age, networth]);
160-
tx.commit();
160+
await tx.commit();
161161
});
162162

163163
const res = await db.execute('SELECT * FROM User');
@@ -176,7 +176,7 @@ export function registerBaseTests() {
176176

177177
await db.writeTransaction(async (tx) => {
178178
await tx.execute('INSERT INTO "User" (id, name, age, networth) VALUES(?, ?, ?, ?)', [id, name, age, networth]);
179-
tx.rollback();
179+
await tx.rollback();
180180
});
181181

182182
const res = await db.execute('SELECT * FROM User');

0 commit comments

Comments
 (0)