Browse Source

⬆️ node-status-codes@2

http2
Sindre Sorhus 9 years ago
parent
commit
25425e3e3a
  1. 4
      package.json
  2. 2
      test/redirects.js

4
package.json

@ -45,14 +45,14 @@
"fetch"
],
"dependencies": {
"create-error-class": "^3.0.0",
"@floatdrop/duplexer2": "^0.1.4",
"create-error-class": "^3.0.0",
"get-stream": "^1.1.0",
"is-plain-obj": "^1.0.0",
"is-redirect": "^1.0.0",
"is-stream": "^1.0.0",
"lowercase-keys": "^1.0.0",
"node-status-codes": "^1.0.0",
"node-status-codes": "^2.0.0",
"timed-out": "^2.0.0",
"unzip-response": "^1.0.0",
"url-parse-lax": "^1.0.0"

2
test/redirects.js

@ -72,7 +72,7 @@ test('redirect only GET and HEAD requests', async t => {
await got(`${s.url}/relative`, {body: 'wow'});
t.fail('Exception was not thrown');
} catch (err) {
t.is(err.message, 'Response code 302 (Moved Temporarily)');
t.is(err.message, 'Response code 302 (Found)');
t.is(err.path, '/relative');
t.is(err.statusCode, 302);
}

Loading…
Cancel
Save