a22c4969e6
And add group.fromJSON(json, userID), which sets editable and filesEditable properties based on the group JSON (libraryReading, role lists, etc.) and the given user
17 lines
383 B
JavaScript
17 lines
383 B
JavaScript
describe("Zotero.Groups", function () {
|
|
describe("#get()", function () {
|
|
it("should retrieve a newly created group", function* () {
|
|
try {
|
|
var group = yield createGroup();
|
|
assert.equal(Zotero.Groups.get(group.id), group)
|
|
}
|
|
finally {
|
|
if (group) {
|
|
yield Zotero.DB.executeTransaction(function* () {
|
|
return group.erase();
|
|
})
|
|
}
|
|
}
|
|
})
|
|
})
|
|
})
|