X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=tests%2Futils%2Fpython%2Ftap%2Fline.py;fp=tests%2Futils%2Fpython%2Ftap%2Fline.py;h=31829582a1dc3b2856f99669af6449f516e5b8dd;hp=e0ed3581df21fb3e87c1647333954158625c05f7;hb=768f9bcbf4b5acd09dda85ab32c0ea30d8826136;hpb=53a47a3f01d6bfa4e940e1943e7645cb89d04cd5 diff --git a/tests/utils/python/tap/line.py b/tests/utils/python/tap/line.py index e0ed3581..31829582 100644 --- a/tests/utils/python/tap/line.py +++ b/tests/utils/python/tap/line.py @@ -8,6 +8,7 @@ class Line(object): TAP is a line based protocol. Thus, the most primitive type is a line. """ + @property def category(self): raise NotImplementedError @@ -17,8 +18,8 @@ class Result(Line): """Information about an individual test line.""" def __init__( - self, ok, number=None, description='', directive=None, - diagnostics=None): + self, ok, number=None, description='', directive=None, diagnostics=None + ): self._ok = ok if number: self._number = int(number) @@ -82,7 +83,8 @@ class Result(Line): if self.diagnostics is not None: diagnostics = '\n' + self.diagnostics.rstrip() return "{0}ok {1} - {2}{3}{4}".format( - is_not, self.number, self.description, directive, diagnostics) + is_not, self.number, self.description, directive, diagnostics + ) class Plan(Line): @@ -173,6 +175,7 @@ class Unknown(Line): This exists for the purpose of a Null Object pattern. """ + @property def category(self): """:returns: ``unknown``"""