changeset 2142:d84535cb9f65

Simplify test template.
author Alexander Schremmer <alex AT alexanderweb DOT de>
date Mon, 18 Jun 2007 00:13:15 +0200
parents 9c7c784281b7
children b97040fcd8e1 3417a1d559d0
files MoinMoin/_tests/_test_template.py
diffstat 1 files changed, 2 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/_tests/_test_template.py	Mon Jun 18 00:02:53 2007 +0200
+++ b/MoinMoin/_tests/_test_template.py	Mon Jun 18 00:13:15 2007 +0200
@@ -31,7 +31,7 @@
         # injected for you into the test class by moin test framework.
         result = module_tested.some_function(self.request, 'test_value')
         expected = 'expected value'
-        assert result == expected, ('Expected "%(expected)s" but got "%(result)s"') % locals()
+        assert result == expected
 
 
 class TestComplexStuff:
@@ -63,8 +63,7 @@
         """ module_tested: function should... """
         for description, test, expected in self._tests:
             result = self._helper_function(test)
-            assert result == expected, ('%(description)s: expected "%(expected)s" '
-                              'but got "%(result)s"') % locals()
+            assert result == expected
 
     def _helper_fuction(self, test):
         """ Some tests needs extra  work to run