diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:14:29 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:14:29 +0000 |
commit | fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8 (patch) | |
tree | 4c1ccaf5486d4f2009f9a338a98a83e886e29c97 /security/manager/ssl/tests/unit/test_oskeystore.js | |
parent | Releasing progress-linux version 124.0.1-1~progress7.99u1. (diff) | |
download | firefox-fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8.tar.xz firefox-fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8.zip |
Merging upstream version 125.0.1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'security/manager/ssl/tests/unit/test_oskeystore.js')
-rw-r--r-- | security/manager/ssl/tests/unit/test_oskeystore.js | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/security/manager/ssl/tests/unit/test_oskeystore.js b/security/manager/ssl/tests/unit/test_oskeystore.js index fcc9de6c59..9efcaa69a6 100644 --- a/security/manager/ssl/tests/unit/test_oskeystore.js +++ b/security/manager/ssl/tests/unit/test_oskeystore.js @@ -51,8 +51,9 @@ async function encrypt_decrypt_test() { // Decrypting should give us the plaintext bytes again. try { let plaintext = await keystore.asyncDecryptBytes(LABELS[0], ciphertext); - ok( - plaintext.toString() == text.toString(), + Assert.equal( + plaintext.toString(), + text.toString(), "Decrypted plaintext should be the same as text." ); } catch (e) { @@ -102,8 +103,9 @@ add_task(async function () { await keystore.asyncRecoverSecret(LABELS[0], recoveryPhrase); let plaintext = await keystore.asyncDecryptBytes(LABELS[0], ciphertext); - ok( - plaintext.toString() == text.toString(), + Assert.equal( + plaintext.toString(), + text.toString(), "Decrypted plaintext should be the same as text." ); @@ -166,8 +168,9 @@ add_task(async function () { await keystore.asyncRecoverSecret(LABELS[0], recoveryPhrase); let plaintext = await keystore.asyncDecryptBytes(LABELS[0], ciphertext); - ok( - plaintext.toString() == text.toString(), + Assert.equal( + plaintext.toString(), + text.toString(), "Decrypted plaintext should be the same as text (once we have the original key again)." ); @@ -204,8 +207,9 @@ add_task(async function () { await keystore.asyncRecoverSecret(LABELS[0], newRecoveryPhrase); let plaintext = await keystore.asyncDecryptBytes(LABELS[0], ciphertext); - ok( - plaintext.toString() == text.toString(), + Assert.equal( + plaintext.toString(), + text.toString(), "Decrypted plaintext should be the same as text (once we have the new key again)." ); |