Files
vpp/test/vpp_papi_exceptions.py
Klement Sekera 77c821ccc6 tests: handle removed interface
Catch exception if sw_if_index is invalid when querying interface
binding config. If the interface is not there, it's surely not bound to
any table ...

Type: improvement
Change-Id: I1f3e04a631653feb5c2350662b6a041adccefa1f
Signed-off-by: Klement Sekera <klement.sekera@gmail.com>
2022-05-03 15:07:41 +00:00

16 lines
404 B
Python

class CliFailedCommandError(Exception):
""" cli command failed."""
class CliSyntaxError(Exception):
""" cli command had a syntax error."""
class UnexpectedApiReturnValueError(Exception):
""" exception raised when the API return value is unexpected """
def __init__(self, retval, message):
self.retval = retval
self.message = message
super().__init__(message)