diff options
author | Tobias Nießen <tniessen@tnie.de> | 2018-01-06 15:30:58 +0100 |
---|---|---|
committer | Tobias Nießen <tniessen@tnie.de> | 2018-01-14 18:41:42 +0100 |
commit | 858b48b692dd04e5134c02f23efac94c4e678329 (patch) | |
tree | 776ed787d1b374e2c07712be0c6f3c8f67dd0404 /test/parallel | |
parent | b12425d055f305a2b69fe925c38ef798aae4b0b2 (diff) | |
download | android-node-v8-858b48b692dd04e5134c02f23efac94c4e678329.tar.gz android-node-v8-858b48b692dd04e5134c02f23efac94c4e678329.tar.bz2 android-node-v8-858b48b692dd04e5134c02f23efac94c4e678329.zip |
crypto: assign deprecation code for setAuthTag/GCM
PR-URL: https://github.com/nodejs/node/pull/18017
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Diffstat (limited to 'test/parallel')
-rw-r--r-- | test/parallel/test-crypto-authenticated.js | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/test/parallel/test-crypto-authenticated.js b/test/parallel/test-crypto-authenticated.js index 221009cb4a..384044210d 100644 --- a/test/parallel/test-crypto-authenticated.js +++ b/test/parallel/test-crypto-authenticated.js @@ -335,13 +335,17 @@ const errMessages = { const ciphers = crypto.getCiphers(); -common.expectWarning('Warning', (common.hasFipsCrypto ? [] : [ - 'Use Cipheriv for counter mode of aes-192-gcm' -]).concat( - [0, 1, 2, 6, 9, 10, 11, 17] +const expectedWarnings = common.hasFipsCrypto ? + [] : ['Use Cipheriv for counter mode of aes-192-gcm']; + +const expectedDeprecationWarnings = [0, 1, 2, 6, 9, 10, 11, 17] .map((i) => `Permitting authentication tag lengths of ${i} bytes is ` + - 'deprecated. Valid GCM tag lengths are 4, 8, 12, 13, 14, 15, 16.') -)); + 'deprecated. Valid GCM tag lengths are 4, 8, 12, 13, 14, 15, 16.'); + +common.expectWarning({ + Warning: expectedWarnings, + DeprecationWarning: expectedDeprecationWarnings +}); for (const test of TEST_CASES) { if (!ciphers.includes(test.algo)) { |