Open robb-j opened 2 years ago
It stopped working because because cameOnline no longer awaits #triggerVisitors.
cameOnline
it('should release the lock', async () => { const { metrics, semaphore, sockets } = setup() mocked(sockets.getSocketsInRoom).mockResolvedValue([ 'socket-a', 'socket-b', 'socket-c', ]) mocked(semaphore.aquire).mockResolvedValue(true) mocked(semaphore.hasLock).mockResolvedValue(true) await metrics.cameOnline('socket-a') expect(semaphore.release).toBeCalledWith('site_visitors') })
It stopped working because because
cameOnline
no longer awaits #triggerVisitors.