Fixed tests and Node version to work with modules

This commit is contained in:
n1474335 2017-08-25 00:44:22 +01:00
parent a4aee761c2
commit 6af82680f1
12 changed files with 12 additions and 12 deletions

View File

@ -12,7 +12,7 @@ import CharEnc from "../../operations/CharEnc.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.CharEnc = {
"Encode text": CharEnc.runEncode,

View File

@ -12,7 +12,7 @@ import Cipher from "../../operations/Cipher.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.Ciphers = {
"AES Encrypt": Cipher.runAesEnc,

View File

@ -16,7 +16,7 @@ import Code from "../../operations/Code.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.Code = {
"JavaScript Parser": JS.runParse,

View File

@ -12,7 +12,7 @@ import Compress from "../../operations/Compress.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.Compression = {
"Raw Deflate": Compress.runRawDeflate,

View File

@ -42,7 +42,7 @@ import UUID from "../../operations/UUID.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.Default = {
"To Hexdump": Hexdump.runTo,

View File

@ -11,7 +11,7 @@ import Diff from "../../operations/Diff.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.Diff = {
"Diff": Diff.runDiff,

View File

@ -11,7 +11,7 @@ import Punycode from "../../operations/Punycode.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.Encodings = {
"To Punycode": Punycode.runToAscii,

View File

@ -11,7 +11,7 @@ import HTTP from "../../operations/HTTP.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.HTTP = {
"HTTP request": HTTP.runHTTPRequest,

View File

@ -14,7 +14,7 @@ import Hash from "../../operations/Hash.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.Hashing = {
"Analyse hash": Hash.runAnalyse,

View File

@ -13,7 +13,7 @@ import Image from "../../operations/Image.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.Image = {
"Extract EXIF": Image.runExtractEXIF,

View File

@ -13,7 +13,7 @@ import Filetime from "../../operations/Filetime.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.JSBN = {
"Parse IP range": IP.runParseIpRange,

View File

@ -11,7 +11,7 @@ import PublicKey from "../../operations/PublicKey.js";
* @copyright Crown Copyright 2017
* @license Apache-2.0
*/
let OpModules = self.OpModules || {};
let OpModules = typeof self === "undefined" ? {} : self.OpModules || {};
OpModules.PublicKey = {
"Parse X.509 certificate": PublicKey.runParseX509,