Fix jwt-token
This commit is contained in:
@@ -103,7 +103,7 @@ describe('Multi-Tenant Authentication Middleware', () => {
|
||||
const res = mockResponse();
|
||||
const next = mockNext();
|
||||
|
||||
await multiAuth.middleware(req, res, next);
|
||||
await multiAuth.authenticate(req, res, next);
|
||||
|
||||
expect(req.tenant).to.equal(tenant.slug);
|
||||
expect(next.errors).to.have.length(0);
|
||||
@@ -116,7 +116,7 @@ describe('Multi-Tenant Authentication Middleware', () => {
|
||||
const res = mockResponse();
|
||||
const next = mockNext();
|
||||
|
||||
await multiAuth.middleware(req, res, next);
|
||||
await multiAuth.authenticate(req, res, next);
|
||||
|
||||
expect(res.statusCode).to.equal(400);
|
||||
expect(res.data).to.deep.equal({
|
||||
@@ -132,7 +132,7 @@ describe('Multi-Tenant Authentication Middleware', () => {
|
||||
const res = mockResponse();
|
||||
const next = mockNext();
|
||||
|
||||
await multiAuth.middleware(req, res, next);
|
||||
await multiAuth.authenticate(req, res, next);
|
||||
|
||||
expect(res.statusCode).to.equal(404);
|
||||
expect(res.data).to.deep.equal({
|
||||
|
||||
Reference in New Issue
Block a user