waldenner / robotframework

Automatically exported from code.google.com/p/robotframework
Apache License 2.0
0 stars 0 forks source link

Disallow using `@{list}` variables with settings that require scalar values to ease parsing #564

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Using list variables with settings that require scalar values is
problematic because the variable may expand into any number of values
(including zero). Consider the example below where it's impossible to split
the setting values into name and arguments reliably:

| Library     | @{VAR1} | arg |
| Suite Setup | @{VAR2} | arg |

As part of refactoring parsing modules (issue 487) we realized that further
processing of the parsed data is a lot easier if setting values can be
split into names and arguments in cases such as above. Tho make that
possible, we decided to disallow using list variables in places where a
scalar value is needed. In practice this means that the above examples
won't work anymore.

The settings that were affected are:
- Library, Resource, and Variables imports
- Setups and Teardowns
- Timeouts

It is still possible to use scalar variables in these places, and list
variables work with arguments. For example these usages are still valid:

| Library     | LibName | @{VAR1} | arg |
| Suite Setup | ${KW}   | @{VAR2} | arg |

Original issue reported on code.google.com by pekka.klarck on 26 May 2010 at 11:16

GoogleCodeExporter commented 9 years ago
This change is already done. The remaining task is documenting this in the User 
Guide.

Original comment by pekka.klarck on 26 May 2010 at 11:17

GoogleCodeExporter commented 9 years ago

Original comment by janne.t....@gmail.com on 26 May 2010 at 1:07

GoogleCodeExporter commented 9 years ago
I added a section about this to the User Guide in r3597. The generated version 
is
visible at:
http://robotframework.googlecode.com/svn/trunk/doc/userguide/RobotFrameworkUserG
uide.html#using-list-variables-with-settings

Could someone review the text and close this issue if it's good enough?

Original comment by pekka.klarck on 27 May 2010 at 8:02

GoogleCodeExporter commented 9 years ago

Original comment by pekka.klarck on 27 May 2010 at 8:09

GoogleCodeExporter commented 9 years ago
Reviewed and updated one variable name r3609, otherwise seems good.

Original comment by jpran...@gmail.com on 28 May 2010 at 6:55

GoogleCodeExporter commented 9 years ago

Original comment by janne.t....@gmail.com on 31 May 2010 at 10:29