summaryrefslogtreecommitdiffstats
path: root/services/sync/modules-testing/fakeservices.sys.mjs
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
commit40a355a42d4a9444dc753c04c6608dade2f06a23 (patch)
tree871fc667d2de662f171103ce5ec067014ef85e61 /services/sync/modules-testing/fakeservices.sys.mjs
parentAdding upstream version 124.0.1. (diff)
downloadfirefox-40a355a42d4a9444dc753c04c6608dade2f06a23.tar.xz
firefox-40a355a42d4a9444dc753c04c6608dade2f06a23.zip
Adding upstream version 125.0.1.upstream/125.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'services/sync/modules-testing/fakeservices.sys.mjs')
-rw-r--r--services/sync/modules-testing/fakeservices.sys.mjs16
1 files changed, 7 insertions, 9 deletions
diff --git a/services/sync/modules-testing/fakeservices.sys.mjs b/services/sync/modules-testing/fakeservices.sys.mjs
index 4fd7534bf1..bf2d143203 100644
--- a/services/sync/modules-testing/fakeservices.sys.mjs
+++ b/services/sync/modules-testing/fakeservices.sys.mjs
@@ -29,7 +29,7 @@ export function FakeFilesystemService(contents) {
self.fakeContents["weave/" + filePath + ".json"] = JSON.stringify(json);
};
- Utils.jsonLoad = async function jsonLoad(filePath, that) {
+ Utils.jsonLoad = async function jsonLoad(filePath) {
let obj;
let json = self.fakeContents["weave/" + filePath + ".json"];
if (json) {
@@ -38,14 +38,14 @@ export function FakeFilesystemService(contents) {
return obj;
};
- Utils.jsonMove = function jsonMove(aFrom, aTo, that) {
+ Utils.jsonMove = function jsonMove(aFrom, aTo) {
const fromPath = "weave/" + aFrom + ".json";
self.fakeContents["weave/" + aTo + ".json"] = self.fakeContents[fromPath];
delete self.fakeContents[fromPath];
return Promise.resolve();
};
- Utils.jsonRemove = function jsonRemove(filePath, that) {
+ Utils.jsonRemove = function jsonRemove(filePath) {
delete self.fakeContents["weave/" + filePath + ".json"];
return Promise.resolve();
};
@@ -79,19 +79,17 @@ export function FakeCryptoService() {
delete Weave.Crypto; // get rid of the getter first
Weave.Crypto = this;
- RawCryptoWrapper.prototype.ciphertextHMAC = function ciphertextHMAC(
- keyBundle
- ) {
+ RawCryptoWrapper.prototype.ciphertextHMAC = function ciphertextHMAC() {
return fakeSHA256HMAC(this.ciphertext);
};
}
FakeCryptoService.prototype = {
- async encrypt(clearText, symmetricKey, iv) {
+ async encrypt(clearText) {
return clearText;
},
- async decrypt(cipherText, symmetricKey, iv) {
+ async decrypt(cipherText) {
return cipherText;
},
@@ -104,7 +102,7 @@ FakeCryptoService.prototype = {
return btoa("fake-fake-fake-random-iv");
},
- expandData: function expandData(data, len) {
+ expandData: function expandData(data) {
return data;
},