Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update for Fastify v5 #63

Merged
merged 3 commits into from
May 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ on:

jobs:
test:
uses: fastify/workflows/.github/workflows/plugins-ci.yml@v3
uses: fastify/workflows/.github/workflows/plugins-ci.yml@v4.2.1
with:
license-check: true
lint: true
node-versions: '["16", "18", "20", "22"]'
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@
"test:typescript": "tsd"
},
"devDependencies": {
"@types/node": "^20.1.0",
"@types/node": "^20.11.30",
"beautify-benchmark": "^0.2.4",
"benchmark": "^2.1.4",
"standard": "^17.0.0",
"tap": "^16.3.0",
"standard": "^17.1.0",
"tap": "^18.7.1",
"tsd": "^0.31.0"
},
"keywords": [
Expand Down
6 changes: 3 additions & 3 deletions test/secret.test.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'use strict'

const { test, mock } = require('tap')
const { test, mockRequire } = require('tap')
const Tokens = require('..')

test('Tokens.secret: should reject bad callback', t => {
Expand Down Expand Up @@ -75,7 +75,7 @@ test('Tokens.secret: should not contain /, +, or =, callback', t => {
test('Tokens.secret: should handle error, Promise', t => {
t.plan(2)

const Tokens = mock('..', {
const Tokens = mockRequire('..', {
'node:crypto': {
randomBytes: (_size, cb) => {
cb(new Error('oh no'))
Expand All @@ -93,7 +93,7 @@ test('Tokens.secret: should handle error, Promise', t => {
test('Tokens.secret: should handle error, callback', t => {
t.plan(2)

const Tokens = mock('..', {
const Tokens = mockRequire('..', {
'node:crypto': {
randomBytes: (size, cb) => {
cb(new Error('oh no'))
Expand Down