diff --git a/test/46.encryption.js b/test/46.encryption.js index 0da8cede..21b80f14 100644 --- a/test/46.encryption.js +++ b/test/46.encryption.js @@ -17,16 +17,11 @@ describe('Encryption using default method (Sqleet)', () => { this.db = new Database(util.current()); expect(() => this.db.prepare('SELECT * FROM user')).to.throw(Database.SqliteError); }); - /* - Temporarily commenting out this test since having `SQLITE_DEBUG` enabled - throws an assertion failure exception if an incorrect passphrase is used. - It cannot be caught in JS which leads to the whole test process being broken. - */ - // it('should not allow access with an incorrect passphrase', () => { - // this.db = new Database(util.current()); - // this.db.pragma(`key='false_passphrase'`); - // expect(() => this.db.prepare('SELECT * FROM user')).to.throw(Database.SqliteError); - // }); + it('should not allow access with an incorrect passphrase', () => { + this.db = new Database(util.current()); + this.db.pragma(`key='false_passphrase'`); + expect(() => this.db.prepare('SELECT * FROM user')).to.throw(Database.SqliteError); + }); it('should allow access with the correct passphrase', () => { this.db = new Database(util.current()); this.db.pragma(`key='passphrase'`);