We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 547615a commit 0ef55c0Copy full SHA for 0ef55c0
1 file changed
packages/common/test/exceptions/http.exception.spec.ts
@@ -25,6 +25,10 @@ describe('HttpException', () => {
25
});
26
27
28
+ it('should return an object even when the message is undefined', () => {
29
+ expect(new BadRequestException().message).to.be.eql({statusCode: 400, error: 'Bad Request'});
30
+ });
31
+
32
it('should return a status code', () => {
33
expect(new BadRequestException().getStatus()).to.be.eql(400);
34
expect(new NotFoundException().getStatus()).to.be.eql(404);
0 commit comments