Changes imports from connector to save to selected collection
Closes #1289
This commit is contained in:
parent
cee2e1d47a
commit
a5a7df328a
2 changed files with 14 additions and 2 deletions
|
@ -513,7 +513,11 @@ describe("Connector Server", function () {
|
|||
assert.equal(error.xmlhttp.status, 400);
|
||||
});
|
||||
|
||||
it('should import resources (BibTeX)', function* () {
|
||||
it('should import resources (BibTeX) into selected collection', function* () {
|
||||
var collection = yield createDataObject('collection');
|
||||
yield waitForItemsLoad(win);
|
||||
|
||||
var addedItemIDPromise = waitForItemEvent('add');
|
||||
var resource = `@book{test1,
|
||||
title={Test1},
|
||||
author={Owl},
|
||||
|
@ -530,6 +534,9 @@ describe("Connector Server", function () {
|
|||
);
|
||||
assert.equal(response.status, 201);
|
||||
assert.equal(JSON.parse(response.responseText)[0].title, 'Test1');
|
||||
|
||||
let itemId = yield addedItemIDPromise;
|
||||
assert.isTrue(collection.hasItem(itemId[0]));
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue