diff --git a/test/check-response.js b/test/check-response.js index e9e1e34a..736ddd21 100644 --- a/test/check-response.js +++ b/test/check-response.js @@ -81,7 +81,7 @@ t.test('log x-fetch-attempts header value', async t => { t.test('log the url fetched', t => { const headers = new Headers() const EE = require('events') - headers.get = header => undefined + headers.get = () => undefined const res = Object.assign({}, mockFetchRes, { headers, status: 200, @@ -110,7 +110,7 @@ t.test('log the url fetched', t => { t.test('redact password from log', t => { const headers = new Headers() const EE = require('events') - headers.get = header => undefined + headers.get = () => undefined const res = Object.assign({}, mockFetchRes, { headers, status: 200, @@ -138,7 +138,7 @@ t.test('redact password from log', t => { t.test('redact well known token from log', t => { const headers = new Headers() const EE = require('events') - headers.get = header => undefined + headers.get = () => undefined const res = Object.assign({}, mockFetchRes, { headers, status: 200, diff --git a/test/errors.js b/test/errors.js index fb71d783..26cad0df 100644 --- a/test/errors.js +++ b/test/errors.js @@ -141,7 +141,7 @@ t.test('OTP error with prompt', async t => { } return true }) - .reply((...args) => { + .reply(() => { if (OTP === '12345') { return [200, { ok: 'this is fine' }, {}] } else { @@ -171,7 +171,7 @@ t.test('OTP error with prompt, expired OTP in settings', async t => { } return true }) - .reply((...args) => { + .reply(() => { if (OTP === '12345') { return [200, { ok: 'this is fine' }, {}] } else { @@ -189,7 +189,7 @@ t.test('OTP error with prompt, expired OTP in settings', async t => { t.test('OTP error with prompt that fails', t => { tnock(t, OPTS.registry) .get('/otplease') - .reply((...args) => { + .reply(() => { return [401, { error: 'otp, please' }, { 'www-authenticate': 'otp' }] }) @@ -202,7 +202,7 @@ t.test('OTP error with prompt that fails', t => { t.test('OTP error with prompt that returns nothing', t => { tnock(t, OPTS.registry) .get('/otplease') - .reply((...args) => { + .reply(() => { return [401, { error: 'otp, please' }, { 'www-authenticate': 'otp' }] })