From 987b31746809dfe04966e37edd759a448a28d975 Mon Sep 17 00:00:00 2001
From: Maximilian Krambach
Date: Mon, 14 May 2018 16:23:24 +0200
Subject: js: Tests and improvements for openpgp mode
--
* Added openpgp - Mode tests to the browsertest Extension. These tests
require openpgp, which should not be a hard dependency for the main
project. Packing openpgpjs into the extension is still TODO
* Fixes:
- openpgp mode API now correctly handles parameters as an object,
similar to openpgpjs
- proper check and parsing of openpgpjs Message Objects
---
lang/js/BrowserTestExtension/index.html | 7 +
lang/js/BrowserTestExtension/openpgpModeTest.html | 23 +++
.../tests/encryptDecryptTest.js | 21 +--
.../tests/inputValues_openpgpjs.js | 32 ++++
lang/js/BrowserTestExtension/tests/inputvalues.js | 131 +++-----------
.../BrowserTestExtension/tests/longRunningTests.js | 1 +
.../BrowserTestExtension/tests/openpgpModeTest.js | 196 +++++++++++++++++++++
7 files changed, 287 insertions(+), 124 deletions(-)
create mode 100644 lang/js/BrowserTestExtension/openpgpModeTest.html
create mode 100644 lang/js/BrowserTestExtension/tests/inputValues_openpgpjs.js
create mode 100644 lang/js/BrowserTestExtension/tests/openpgpModeTest.js
(limited to 'lang/js/BrowserTestExtension')
diff --git a/lang/js/BrowserTestExtension/index.html b/lang/js/BrowserTestExtension/index.html
index 05d413ba..c49aedae 100644
--- a/lang/js/BrowserTestExtension/index.html
+++ b/lang/js/BrowserTestExtension/index.html
@@ -34,6 +34,13 @@
Functionality tests with larger/longer running data sets.
+
+
+ Testing openPGP mode.
+ - Please notice that, due to comparing
+ the inputs and outputs with openpgpjs objects, this test
+ requires a copy of openpgpjs in libs.
+
+ Openpgp mode test
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/lang/js/BrowserTestExtension/openpgpModeTest.html b/lang/js/BrowserTestExtension/openpgpModeTest.html
new file mode 100644
index 00000000..e7a12be9
--- /dev/null
+++ b/lang/js/BrowserTestExtension/openpgpModeTest.html
@@ -0,0 +1,23 @@
+
+
+