You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
describe('nestjs event emitter',()=>{it('(GET) /nestjs/ok - should be 200',()=>{returnrequest(app.getHttpServer()).get('/nestjs/ok').expect(200).expect(['ok']);});it('(GET) /nestjs/error - should be 200',()=>{returnrequest(app.getHttpServer()).get('/nestjs/error').expect(200).expect([null]);});it('(GET) /nestjs/exception - should be 200',()=>{returnrequest(app.getHttpServer()).get('/nestjs/exception').expect(200).expect([null]);});});
describe('safery event emitter',()=>{it('(GET) /safety/ok - should be 200',()=>{returnrequest(app.getHttpServer()).get('/safety/ok').expect(200).expect(['ok']);});it('(GET) /safety/error - should be 500',()=>{returnrequest(app.getHttpServer()).get('/safety/error').expect(500).expect(newInternalServerErrorException(SafetyEventSubject.Error).getResponse());});it('(GET) /safety/exception - should be 400',()=>{returnrequest(app.getHttpServer()).get('/safety/exception').expect(400).expect(newBadRequestException(SafetyEventSubject.Exception).getResponse());});});
describe('safery event emitter with ignore error',()=>{it('(GET) /safety/error/ignore - should be 200',()=>{returnrequest(app.getHttpServer()).get('/safety/error/ignore').expect(200).expect([JSON.parse(JSON.stringify(newError(SafetyEventSubject.Error)))]);});it('(GET) /safety/exception/ignore - should be 200',()=>{returnrequest(app.getHttpServer()).get('/safety/exception/ignore').expect(200).expect([JSON.parse(JSON.stringify(newBadRequestException(SafetyEventSubject.Exception)))]);});});