From 25c82c64812e8e031fa3500c3fae5aa650e248cb Mon Sep 17 00:00:00 2001 From: Jonathan Lange Date: Tue, 1 Nov 2011 11:39:51 -0400 Subject: Put output_summary in the UI interface. --- testrepository/ui/__init__.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'testrepository/ui/__init__.py') diff --git a/testrepository/ui/__init__.py b/testrepository/ui/__init__.py index 7df5bf2..b608a61 100644 --- a/testrepository/ui/__init__.py +++ b/testrepository/ui/__init__.py @@ -140,6 +140,21 @@ class AbstractUI(object): """ raise NotImplementedError(self.output_values) + def output_summary(self, successful, values): + """Output a summary of a test run. + + An example summary might look like: + Run 565 (+2) tests in 2.968s + FAILED (errors=13 (-2), succeesses=31 (+2)) + + :param successful: A boolean indicating whether the result was + successful. + :param values: A dict mapping from name (e.g. "successes") to a tuple + of ``(value, delta)``. e.g. (31, -2) + + """ + raise NotImplementedError(self.output_summary) + def set_command(self, cmd): """Inform the UI what command it is running. -- cgit v1.2.1