Update ApiCacheManager unit test

This commit is contained in:
advplyr 2024-08-06 17:26:36 -05:00
parent 9f561aa296
commit 2c8ebd43cc

View File

@ -11,8 +11,8 @@ describe('ApiCacheManager', () => {
let manager let manager
beforeEach(() => { beforeEach(() => {
cache = { get: sinon.stub(), set: sinon.spy() } cache = { get: sinon.stub(), set: sinon.spy() }
req = { user: { username: 'testUser' }, url: '/test-url' } req = { user: { username: 'testUser' }, url: '/test-url', query: {} }
res = { send: sinon.spy(), getHeaders: sinon.stub(), statusCode: 200, status: sinon.spy(), set: sinon.spy() } res = { send: sinon.spy(), getHeaders: sinon.stub(), statusCode: 200, status: sinon.spy(), set: sinon.spy() }
next = sinon.spy() next = sinon.spy()
}) })
@ -94,4 +94,4 @@ describe('ApiCacheManager', () => {
expect(res.originalSend.calledWith(body)).to.be.true expect(res.originalSend.calledWith(body)).to.be.true
}) })
}) })
}) })