The problem is with SeleniumLibrary, because if the link is not in the
page, I will get an error. I know that Robot doesn't have "if - else"
conditionals, but in this case I think could be helpful.
It was solved using the keyword: "Run Keyword And Ignore Error" and an
auxiliary keyword with the link (If the link is not in the page, it
will be stopped but the test will not fail).
Is there another better way to do that?
Cheers,
Cristian
But why not test with a know data set and have a constant and
predictable number of rows in your table?
--
Radek
This is a good idea. I'd go a step further and have keyword like
`Click link if it exists` so that all the logic is hidden inside it.
> But why not test with a know data set and have a constant and
> predictable number of rows in your table?
This is definitely the best solution for this kind of problems. I know
conditional logic cannot always be avoided, but adding logic into test
cases both makes their maintenance harder and can lead to a situation
where the test status depends on what if/else branch it happens to
execute.
Cheers,
.peke
--
Agile Tester/Developer/Consultant :: http://eliga.fi
Lead Developer of Robot Framework :: http://robotframework.org