Projektstart
This commit is contained in:
17
backend/node_modules/light-my-request/test/response.test.js
generated
vendored
Normal file
17
backend/node_modules/light-my-request/test/response.test.js
generated
vendored
Normal file
@@ -0,0 +1,17 @@
|
||||
'use strict'
|
||||
|
||||
const { test } = require('tap')
|
||||
|
||||
const Response = require('../lib/response')
|
||||
|
||||
test('multiple calls to res.destroy should not be called', (t) => {
|
||||
t.plan(1)
|
||||
|
||||
const mockReq = {}
|
||||
const res = new Response(mockReq, (err, response) => {
|
||||
t.error(err)
|
||||
})
|
||||
|
||||
res.destroy()
|
||||
res.destroy()
|
||||
})
|
||||
Reference in New Issue
Block a user