Fix binary file output and eslint warnings

This commit is contained in:
toby 2017-03-15 12:33:38 -04:00
parent db261be707
commit f2f3bdc923
2 changed files with 7 additions and 7 deletions

View file

@ -297,7 +297,7 @@ var PGP = {
}, { }, {
fileName: "msg.sig", fileName: "msg.sig",
size: rawSignatureBytes.length, size: rawSignatureBytes.length,
contents: "Binary file", contents: openpgp.util.Uint8Array2str(rawSignatureBytes),
bytes: rawSignatureBytes, bytes: rawSignatureBytes,
}]; }];

View file

@ -201,11 +201,11 @@ PGP_TEST_KEY_PAIRS.forEach(function(keyPair) {
if (keyPair.password) { if (keyPair.password) {
TestRegister.addTests( TestRegister.addTests(
["", "nottherightpassword"].map(function(incorrectPW) { ["", "nottherightpassword"].map(function(incorrectPW) {
var testName = "PGP Encrypt, PGP Decrypt: ensure error for incorrect password (pw [$pw], $ks, $name)"; var testName = "PGP Encrypt, PGP Decrypt: ensure error for incorrect password (pw [$pw], $ks, $name)";
testName = testName.replace("$ks", keyPair.size); testName = testName.replace("$ks", keyPair.size);
testName = testName.replace("$pw", incorrectPW); testName = testName.replace("$pw", incorrectPW);
return { return {
name: testName, name: testName,
input: "hello world", input: "hello world",
expectedError: true, expectedError: true,
@ -443,5 +443,5 @@ PGP_TEST_KEY_PAIRS.forEach(function(keyPair) {
], ],
}; };
}) })
) );
}); });