diff --git a/chrome/content/zotero/xpcom/data/collection.js b/chrome/content/zotero/xpcom/data/collection.js index f3e2d9624f..d314ec4a1f 100644 --- a/chrome/content/zotero/xpcom/data/collection.js +++ b/chrome/content/zotero/xpcom/data/collection.js @@ -296,7 +296,6 @@ Zotero.Collection.prototype._saveData = Zotero.Promise.coroutine(function* (env) 'collectionID', 'collectionName', 'parentCollectionID', - 'clientDateModified', 'libraryID', 'key', 'version', @@ -306,7 +305,6 @@ Zotero.Collection.prototype._saveData = Zotero.Promise.coroutine(function* (env) collectionID ? { int: collectionID } : null, { string: this.name }, env.parent ? env.parent : null, - Zotero.DB.transactionDateTime, this.libraryID, key, this.version ? this.version : 0, diff --git a/test/tests/collectionTest.js b/test/tests/collectionTest.js new file mode 100644 index 0000000000..85197826c8 --- /dev/null +++ b/test/tests/collectionTest.js @@ -0,0 +1,13 @@ +describe("Zotero.Collection", function() { + describe("#save()", function () { + it("should save a new collection", function* () { + var name = "Test"; + + var collection = new Zotero.Collection; + collection.name = name; + var id = yield collection.save(); + collection = yield Zotero.Collections.getAsync(id); + assert.equal(collection.name, name); + }); + }) +})