From 5e03c718f4e7ff13cb6834eda737c269ebed02ad Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 19:04:52 +0200 Subject: Adding upstream version 1.21.3. Signed-off-by: Daniel Baumann --- testenv/exc/server_error.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 testenv/exc/server_error.py (limited to 'testenv/exc/server_error.py') diff --git a/testenv/exc/server_error.py b/testenv/exc/server_error.py new file mode 100644 index 0000000..fe359f5 --- /dev/null +++ b/testenv/exc/server_error.py @@ -0,0 +1,19 @@ + +class ServerError (Exception): + """ A custom exception which is raised by the test servers. Often used to + handle control flow. """ + + def __init__(self, err_message): + self.err_message = err_message + +class NoBodyServerError (Exception): + """ A custom exception which is raised by the test servers. + Used if no body should be sent in response. """ + + def __init__(self, err_message): + self.err_message = err_message + +class AuthError (ServerError): + """ A custom exception raised byt he servers when authentication of the + request fails. """ + pass -- cgit v1.2.3