Revision: 3682
Author: jussi.ao.malinen
Date: Mon May 31 02:31:58 2010
Log: Always get the timeout error message when timeout occurred
http://code.google.com/p/robotframework/source/detail?r=3682

Modified:
 /trunk/src/robot/running/timeouts.py

=======================================
--- /trunk/src/robot/running/timeouts.py        Mon May 31 00:22:22 2010
+++ /trunk/src/robot/running/timeouts.py        Mon May 31 02:31:58 2010
@@ -88,7 +88,7 @@
         except:
             raise TimeoutError('Stopping keyword after %s failed: %s'
% (self.type.lower(), utils.get_error_message()))
-        raise TimeoutError(self.get_message())
+        raise TimeoutError(self._get_timeout_error())

     def get_message(self):
         if not self.active:
@@ -98,6 +98,9 @@
                                                        self.time_left())
         if self.message:
             return self.message
+        return self._get_timeout_error()
+
+    def _get_timeout_error(self):
         return '%s %s exceeded.' % (self.type, self.string)


Reply via email to