2014-10-22 12:36 GMT+03:00 Roman Fominych <
r.fom...@gmail.com>:
> following code runs as expected, two keywords are separated by "AND"
> separator
>
[snip]
>
> But if keywords are loaded to variable, then separator is not recognized,
> and all list items are run one by one
This is by design. The reason is that you cannot always control what
values your variables contain, and thus you cannot realistically be
expected to escape AND with Run Keywords or ELSE/ELSE IF with Run
Keyword If. Notice that all this Run Keyword variants are special
because they resolve variables themselves, typically variables are
replace already by Robot before keywords are called. The motivation
for that behavior is to allow e.g. Run Keyword If to contain
non-existing variables in arguments when the given expression is not
true.
There is no easy way to support AND coming from a variable with Run
Keywords. Probably the easiest solution is writing your own keyword
that handles it. It would get all arguments so that variables are
already replaced, and could then, for example, call
BuiltIn().run_keywords internally.
Cheers,
.peke
--
Agile Tester/Developer/Consultant ::
http://eliga.fi
Lead Developer of Robot Framework ::
http://robotframework.org