Coverage for audoma_api/exceptions.py: 100%
8 statements
« prev ^ index » next coverage.py v6.4.2, created at 2022-08-04 07:22 +0000
« prev ^ index » next coverage.py v6.4.2, created at 2022-08-04 07:22 +0000
1from rest_framework import status
2from rest_framework.exceptions import APIException
5class CustomBadRequestException(APIException):
6 status_code = status.HTTP_400_BAD_REQUEST
7 default_detail = "Custom Bad Request Exception"
10class CustomConflictException(APIException):
11 status_code = status.HTTP_409_CONFLICT
12 default_detail = "Conflict has occured"