From 703c83ea72db2f45714fe749c6f04b05243ca9a8 Mon Sep 17 00:00:00 2001 From: Jordan Harband Date: Mon, 18 Sep 2023 11:44:21 -0700 Subject: [PATCH] [Tests] skip unsupported schemes without this, id crashes in node 17 --- test/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/index.js b/test/index.js index f6f63ad..d65a03e 100644 --- a/test/index.js +++ b/test/index.js @@ -28,7 +28,7 @@ fixtures.valid.rsa.forEach(function (f) { priv = Buffer.from(f['private'], 'base64'); } - test(f.message, function (t) { + (nCrypto.getHashes().indexOf(f.scheme) >= 0 ? test : test.skip)(f.message, function (t) { var bSign = bCrypto.createSign(f.scheme); var nSign = nCrypto.createSign(f.scheme); var bSig = bSign.update(message).sign(priv);