2 new revisions:

Revision: 60f3b99e0a77
Branch:   default
Author:   Pekka Klärck
Date:     Thu May 30 23:11:35 2013
Log: fixed dry-run with run keyword variants w/ python/jython 2.5. the bug ...
http://code.google.com/p/robotframework/source/detail?r=60f3b99e0a77

Revision: 9eaf6ff4d41a
Branch:   default
Author:   Pekka Klärck
Date:     Thu May 30 23:15:48 2013
Log:      Automated merge with https://code.google.com/p/robotframework/
http://code.google.com/p/robotframework/source/detail?r=9eaf6ff4d41a

==============================================================================
Revision: 60f3b99e0a77
Branch:   default
Author:   Pekka Klärck
Date:     Thu May 30 23:11:35 2013
Log: fixed dry-run with run keyword variants w/ python/jython 2.5. the bug was caused the code using tuple.index() which is only available in 2.6+.
http://code.google.com/p/robotframework/source/detail?r=60f3b99e0a77

Modified:
 /src/robot/libraries/BuiltIn.py
 /src/robot/running/handlers.py

=======================================
--- /src/robot/libraries/BuiltIn.py     Thu May 30 08:46:01 2013
+++ /src/robot/libraries/BuiltIn.py     Thu May 30 23:11:35 2013
@@ -27,7 +27,6 @@
 from robot.running.context import EXECUTION_CONTEXTS
 from robot.common import UserErrorHandler
 from robot.version import get_version
-from robot.model import TagPatterns

 if utils.is_jython:
     from java.lang import String, Number
@@ -1219,8 +1218,7 @@
         return args, lambda: None

     def _split_branch(self, args, control_word, required, required_error):
-        args = list(args)
-        index = args.index(control_word)
+        index = list(args).index(control_word)
         branch = self._variables.replace_list(args[index+1:], required)
         if len(branch) < required:
raise DataError('%s requires %s.' % (control_word, required_error))
=======================================
--- /src/robot/running/handlers.py      Mon May 27 02:51:51 2013
+++ /src/robot/running/handlers.py      Thu May 30 23:11:35 2013
@@ -308,14 +308,14 @@
                 yield kw_call

def _split_run_kw_if_args(self, given_args, control_word, required_after):
-        index = given_args.index(control_word)
+        index = list(given_args).index(control_word)
         expr_and_call = given_args[:index]
         remaining = given_args[index+1:]
         if not (self._validate_kw_call(expr_and_call) and
                 self._validate_kw_call(remaining, required_after)):
             raise DataError("Invalid 'Run Keyword If' usage.")
         if is_list_var(expr_and_call[0]):
-            return [], remaining
+            return (), remaining
         return expr_and_call[1:], remaining

     def _validate_kw_call(self, kw_call, min_length=2):
@@ -333,14 +333,14 @@
                 yield [kw_call,]
         else:
             while 'AND' in given_args:
-                index = given_args.index('AND')
+                index = list(given_args).index('AND')
kw_call, given_args = given_args[:index], given_args[index + 1:]
                 yield kw_call
             if given_args:
                 yield given_args

     def _get_default_run_kw_keywords(self, given_args):
-        index = self.arguments.positional.index('name')
+        index = list(self.arguments.positional).index('name')
         return [Keyword(given_args[index], given_args[index+1:])]



==============================================================================
Revision: 9eaf6ff4d41a
Branch:   default
Author:   Pekka Klärck
Date:     Thu May 30 23:15:48 2013
Log:      Automated merge with https://code.google.com/p/robotframework/
http://code.google.com/p/robotframework/source/detail?r=9eaf6ff4d41a


--

--- You received this message because you are subscribed to the Google Groups "robotframework-commit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to