diff --git a/signer.js b/signer.js index 38bad49..a19ceb0 100644 --- a/signer.js +++ b/signer.js @@ -6,7 +6,7 @@ // The MIT License // Copyright (c) 2012–2022 LearnBoost and other contributors; -const crypto = require('crypto') +const crypto = require('node:crypto') const base64PaddingRE = /=/g diff --git a/test/cookie.test.js b/test/cookie.test.js index 6b08813..767302a 100644 --- a/test/cookie.test.js +++ b/test/cookie.test.js @@ -1,7 +1,6 @@ 'use strict' -const tap = require('tap') -const test = tap.test +const { test } = require('tap') const Fastify = require('fastify') const sinon = require('sinon') const { sign, unsign } = require('../signer') diff --git a/test/signer.test.js b/test/signer.test.js index 9b96faa..1ac7224 100644 --- a/test/signer.test.js +++ b/test/signer.test.js @@ -2,7 +2,7 @@ const { test } = require('tap') const sinon = require('sinon') -const crypto = require('crypto') +const crypto = require('node:crypto') const { Signer, sign, unsign } = require('../signer') test('default', t => {