Fix drive tests

pull/1/head
yflory 6 years ago
parent 8ab786e7df
commit bad1d7311a

@ -697,12 +697,12 @@ define([
}); });
}; };
fixSharedFolders();
fixRoot(); fixRoot();
fixTrashRoot(); fixTrashRoot();
fixTemplate(); fixTemplate();
fixFilesData(); fixFilesData();
fixDrive(); fixDrive();
fixSharedFolders();
if (JSON.stringify(files) !== before) { if (JSON.stringify(files) !== before) {
debug("Your file system was corrupted. It has been cleaned so that the pads you visit can be stored safely"); debug("Your file system was corrupted. It has been cleaned so that the pads you visit can be stored safely");

@ -432,6 +432,7 @@ define([
var validate = nSecret.keys.validateKey; var validate = nSecret.keys.validateKey;
var crypto = Crypto.createEncryptor(nSecret.keys); var crypto = Crypto.createEncryptor(nSecret.keys);
Cryptpad.getHistoryRange({ Cryptpad.getHistoryRange({
drive: cfg.isDrive,
channel: channel, channel: channel,
validateKey: validate, validateKey: validate,
lastKnownHash: data.lastKnownHash lastKnownHash: data.lastKnownHash

@ -83,7 +83,7 @@ define([
var isSharedFolder = exp.isSharedFolder = function (element) { var isSharedFolder = exp.isSharedFolder = function (element) {
if (sharedFolder) { return false; } // No recursive shared folders if (sharedFolder) { return false; } // No recursive shared folders
return Boolean(files[SHARED_FOLDERS][element]); return Boolean(files[SHARED_FOLDERS] && files[SHARED_FOLDERS][element]);
}; };
var isFile = exp.isFile = function (element, allowStr) { var isFile = exp.isFile = function (element, allowStr) {
if (isSharedFolder(element)) { return false; } if (isSharedFolder(element)) { return false; }

@ -70,7 +70,7 @@ define([
module.test = function (assert) { module.test = function (assert) {
var config = { var config = {
pinPads: Cryptpad.pinPads, outer: true,
workgroup: false, workgroup: false,
testMode: true, testMode: true,
loggedIn: false loggedIn: false

Loading…
Cancel
Save