Set test timeout in resetDB() instead of separate this.timeout() calls
'thisArg: this' should be passed to resetDB to have it adjust the timeout
This commit is contained in:
parent
88627adcdb
commit
7633c7de30
4 changed files with 14 additions and 8 deletions
|
@ -426,6 +426,9 @@ var getTempDirectory = Zotero.Promise.coroutine(function* getTempDirectory() {
|
|||
* any that were set at startup
|
||||
*/
|
||||
function resetDB(options = {}) {
|
||||
if (options.thisArg) {
|
||||
options.thisArg.timeout(60000);
|
||||
}
|
||||
var db = Zotero.getZoteroDatabase();
|
||||
return Zotero.reinit(function() {
|
||||
db.remove(false);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue