diff --git a/test/tests/zoteroPaneTest.js b/test/tests/zoteroPaneTest.js index 7ed98c4be..142beeeaa 100644 --- a/test/tests/zoteroPaneTest.js +++ b/test/tests/zoteroPaneTest.js @@ -221,8 +221,15 @@ describe("ZoteroPane", function() { } ); + // Disable loadURI() so viewAttachment() doesn't trigger translator loading + var stub = sinon.stub(zp, "loadURI"); + yield zp.viewAttachment(item.id); + assert.ok(stub.calledOnce); + assert.ok(stub.calledWith(OS.Path.toFileURI(item.getFilePath()))); + stub.restore(); + assert.equal((yield item.attachmentHash), md5); assert.equal((yield item.attachmentModificationTime), mtime); var path = yield item.getFilePathAsync();