You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When dynamically calculating the names of global variables to set and passing those to Set Global Variable, the name of the variable that is passed to Set Global Variable is interpreted as the name that Set Global Variable is going to use, which is incorrect.
$ tail -2 my_file.robot
${name}= "MY UPPERCASE VARIABLE NAME"
Set Global Variable ${${name}} "My variable value"
$ robocop --include non-local-variables-should-be-uppercase my_file.robot
/my_path/my_file.robot:17:29 [W] 0310 Test, suite and global variables should be uppercase (non-local-variables-should-be-uppercase)
$
What did you expect to happen instead?
Robocop shouldn't flag this. It can't figure out the possible values of ${name} in the above example if $name} is an argument being passed in to a keyword with this Set Global Variable call, for example, so it should exclude any cases of variables being used as the variable name in the Set Global Variable call.
Operating System
No response
Robocop version
5.5.0
The text was updated successfully, but these errors were encountered:
What happened?
When dynamically calculating the names of global variables to set and passing those to Set Global Variable, the name of the variable that is passed to Set Global Variable is interpreted as the name that Set Global Variable is going to use, which is incorrect.
What command/code did you try to run?
What is the full error message?
What did you expect to happen instead?
Robocop shouldn't flag this. It can't figure out the possible values of
${name}
in the above example if$name}
is an argument being passed in to a keyword with thisSet Global Variable
call, for example, so it should exclude any cases of variables being used as the variable name in theSet Global Variable
call.Operating System
No response
Robocop version
5.5.0
The text was updated successfully, but these errors were encountered: