@neoskop/ethereal-secrets-middleware
Advanced tools
Comparing version 4.0.5 to 4.0.7
@@ -9,3 +9,3 @@ "use strict"; | ||
const index_1 = require("../index"); | ||
const chaiHttp = require("chai-http"); | ||
const chai_http_1 = require("chai-http"); | ||
const chaiUuid = require("chai-uuid"); | ||
@@ -18,3 +18,3 @@ const UuidStatic = require("uuid"); | ||
redis = new ioredis_1.default({ host: 'redis' }); | ||
chai.use(chaiHttp); | ||
chai.use(chai_http_1.default); | ||
chai.use(chaiUuid); | ||
@@ -55,3 +55,3 @@ done(); | ||
try { | ||
const res = await chai.request.agent(app).put('/secrets/'); | ||
const res = await chai_http_1.request.agent(app).put('/secrets/'); | ||
return chai.expect(res).to.have.status(418); | ||
@@ -70,4 +70,4 @@ } | ||
})); | ||
const res = await chai | ||
.request(app) | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
.get('/secrets') | ||
@@ -86,3 +86,3 @@ .set('Accept', 'application/json'); | ||
})); | ||
let agent = chai.request.agent(app); | ||
let agent = chai_http_1.request.agent(app); | ||
const firstRes = await agent | ||
@@ -103,8 +103,8 @@ .get('/secrets') | ||
})); | ||
const firstRes = await chai | ||
.request(app) | ||
const firstRes = await chai_http_1.request | ||
.agent(app) | ||
.get('/secrets') | ||
.set('Accept', 'application/json'); | ||
const secondRes = await chai | ||
.request(app) | ||
const secondRes = await chai_http_1.request | ||
.agent(app) | ||
.get('/secrets') | ||
@@ -121,3 +121,3 @@ .set('Accept', 'application/json'); | ||
})); | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -141,3 +141,3 @@ .get('/secrets') | ||
})); | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -155,3 +155,3 @@ .get('/secrets') | ||
setupRemoteMiddleware.call(this); | ||
const res = await chai.request(app).post('/secrets').send({ | ||
const res = await chai_http_1.request.agent(app).post('/secrets').send({ | ||
data: 'foo', | ||
@@ -167,3 +167,3 @@ }); | ||
setupRemoteMiddleware.call(this); | ||
const res = await chai.request(app).post('/secrets').send({ | ||
const res = await chai_http_1.request.agent(app).post('/secrets').send({ | ||
data: 'foo', | ||
@@ -185,3 +185,3 @@ ttl: 1337, | ||
try { | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -198,3 +198,3 @@ .post('/secrets') | ||
setupRemoteMiddleware.call(this); | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -207,3 +207,3 @@ .post('/secrets') | ||
let key = res.body['key']; | ||
const res2 = await chai.request.agent(app).get('/secrets/' + key); | ||
const res2 = await chai_http_1.request.agent(app).get('/secrets/' + key); | ||
return await Promise.all([ | ||
@@ -218,3 +218,3 @@ chai.expect(res2).to.have.status(200), | ||
try { | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -232,3 +232,3 @@ .get('/secrets/foobar') | ||
try { | ||
const res = await chai.request.agent(app).del('/secrets/foobar'); | ||
const res = await chai_http_1.request.agent(app).del('/secrets/foobar'); | ||
return chai.expect(res).to.have.status(400); | ||
@@ -243,3 +243,3 @@ } | ||
try { | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -257,3 +257,3 @@ .get('/secrets/' + UuidStatic.v4()) | ||
try { | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -266,4 +266,4 @@ .post('/secrets') | ||
let key = res.body['key']; | ||
await chai.request.agent(app).del('/secrets/' + key); | ||
const res2 = await chai.request.agent(app).get('/secrets/' + key); | ||
await chai_http_1.request.agent(app).del('/secrets/' + key); | ||
const res2 = await chai_http_1.request.agent(app).get('/secrets/' + key); | ||
chai.expect(res2).to.have.status(404); | ||
@@ -277,3 +277,3 @@ } | ||
setupRemoteMiddleware.call(this, { defaultTtl: 9 }); | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -294,3 +294,3 @@ .post('/secrets') | ||
setupRemoteMiddleware.call(this); | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -310,3 +310,3 @@ .post('/secrets') | ||
setupRemoteMiddleware.call(this); | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -328,3 +328,3 @@ .post('/secrets') | ||
}); | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -345,3 +345,3 @@ .post('/secrets') | ||
try { | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -369,3 +369,3 @@ .post('/secrets') | ||
})); | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -387,3 +387,3 @@ .get('/secrets') | ||
}); | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -404,3 +404,3 @@ .get('/secrets/' + key + '?secondFactor=bar'); | ||
try { | ||
const res = await chai.request.agent(app).get('/secrets/' + key); | ||
const res = await chai_http_1.request.agent(app).get('/secrets/' + key); | ||
chai.expect(res).to.have.status(401); | ||
@@ -424,3 +424,3 @@ } | ||
try { | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -446,3 +446,3 @@ .get('/secrets/' + key + '?secondFactor=baz'); | ||
try { | ||
const res = await chai.request.agent(app).delete('/secrets/' + key); | ||
const res = await chai_http_1.request.agent(app).delete('/secrets/' + key); | ||
chai.expect(res).to.have.status(401); | ||
@@ -466,3 +466,3 @@ } | ||
try { | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -487,3 +487,3 @@ .delete('/secrets/' + key + '?secondFactor=baz'); | ||
}); | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -508,3 +508,3 @@ .delete('/secrets/' + key + '?secondFactor=bar'); | ||
async function storeRemoteData(data) { | ||
const res = await chai.request | ||
const res = await chai_http_1.request | ||
.agent(app) | ||
@@ -511,0 +511,0 @@ .post('/secrets') |
{ | ||
"name": "@neoskop/ethereal-secrets-middleware", | ||
"version": "4.0.5", | ||
"version": "4.0.7", | ||
"main": "dist/index.js", | ||
@@ -24,23 +24,24 @@ "typings": "dist/index.d.ts", | ||
"@types/body-parser": "1.19.5", | ||
"@types/chai": "4.3.19", | ||
"@types/chai": "5.0.0", | ||
"@types/cookie-parser": "1.4.7", | ||
"@types/express": "4.17.21", | ||
"@types/express": "5.0.0", | ||
"@types/express-session": "1.18.0", | ||
"@types/ioredis": "5.0.0", | ||
"@types/mocha": "10.0.8", | ||
"@types/mocha": "10.0.9", | ||
"@types/redis": "4.0.11", | ||
"@types/sinon": "17.0.3", | ||
"@types/superagent": "8.1.9", | ||
"@types/uuid": "10.0.0", | ||
"@types/validator": "13.12.2", | ||
"chai": "5.1.1", | ||
"chai-http": "4.4.0", | ||
"chai-http": "5.1.1", | ||
"chai-uuid": "1.0.6", | ||
"concurrently": "9.0.1", | ||
"cookie-parser": "1.4.6", | ||
"cookie-parser": "1.4.7", | ||
"mocha": "10.7.3", | ||
"nyc": "17.0.0", | ||
"nyc": "17.1.0", | ||
"rimraf": "6.0.1", | ||
"sinon": "19.0.2", | ||
"ts-node": "10.9.2", | ||
"typescript": "5.6.2" | ||
"typescript": "5.6.3" | ||
}, | ||
@@ -51,4 +52,4 @@ "dependencies": { | ||
"deepmerge": "4.3.1", | ||
"express": "4.21.0", | ||
"express-session": "1.18.0", | ||
"express": "4.21.1", | ||
"express-session": "1.18.1", | ||
"ioredis": "5.4.1", | ||
@@ -55,0 +56,0 @@ "uuid": "10.0.0", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
89906
23
+ Addedcookie@0.7.10.7.2(transitive)
+ Addedexpress@4.21.1(transitive)
+ Addedexpress-session@1.18.1(transitive)
- Removedcookie@0.6.0(transitive)
- Removedexpress@4.21.0(transitive)
- Removedexpress-session@1.18.0(transitive)
Updatedexpress@4.21.1
Updatedexpress-session@1.18.1