MCPcopy Index your code
hub / github.com/nodeSolidServer/node-solid-server / describeHeaderTest

Function describeHeaderTest

test/integration/header-test.mjs:71–86  ·  view source on GitHub ↗
(label, { resource, headers })

Source from the content-addressed store, hash-verified

69 })
70
71 function describeHeaderTest (label, { resource, headers }) {
72 describe(`a resource that is ${label}`, () => {
73 // Retrieve the response headers
74 const response = {}
75 before(async function () {
76 this.timeout(10000) // FIXME: https://github.com/solid/node-solid-server/issues/1443
77 const { headers } = await request.get(resource)
78 response.headers = headers
79 })
80
81 // Assert the existence of each of the expected headers
82 for (const header in headers) {
83 assertResponseHasHeader(response, header, headers[header])
84 }
85 })
86 }
87
88 function assertResponseHasHeader (response, name, value) {
89 const key = name.toLowerCase()

Callers 1

header-test.mjsFile · 0.85

Calls 2

assertResponseHasHeaderFunction · 0.85
getMethod · 0.45

Tested by

no test coverage detected