www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README | LICENSE

commit 74d1cc193a69bb33fc259b695c373a2351ffeca7
parent b21729edd17c8bebea266abec89008e40b0fc617
Author: Dan Stillman <dstillman@zotero.org>
Date:   Fri, 24 Feb 2017 00:09:13 -0500

Check database values in Zotero.Library#editable tests

Diffstat:
Mtest/tests/libraryTest.js | 2++
1 file changed, 2 insertions(+), 0 deletions(-)

diff --git a/test/tests/libraryTest.js b/test/tests/libraryTest.js @@ -73,11 +73,13 @@ describe("Zotero.Library", function() { assert.isTrue(library.editable); assert.isTrue(Zotero.Libraries.isEditable(library.libraryID), "sets editable in cache to true"); + assert.equal((yield Zotero.DB.valueQueryAsync("SELECT editable FROM libraries WHERE libraryID=?", library.libraryID)), 1) library.editable = false; yield library.saveTx(); assert.isFalse(library.editable); assert.isFalse(Zotero.Libraries.isEditable(library.libraryID), "sets editable in cache to false"); + assert.equal((yield Zotero.DB.valueQueryAsync("SELECT editable FROM libraries WHERE libraryID=?", library.libraryID)), 0) }); it("should not be settable for user and publications libraries", function* () { let library = Zotero.Libraries.get(Zotero.Libraries.userLibraryID);