0

I have a list with data as float or number and I need to convert it to String for comparison with robotframework with another dataset which is in String only.

I tierd string operations from robotframework but I didn't found anything to convert float to String.

8
  • Float to String conversion is a question that should be asked on other boards.
    – Moro
    Sep 27, 2019 at 11:53
  • I disagree with this being off-topic. Robotframework is a keyword driven testing framework. We answer plenty of questions about Selenium here, so I'm not sure why a programming question specific to Robotframework is off-topic.
    – anonygoose
    Sep 27, 2019 at 12:52
  • Any help would be appreciated regarding question Sep 27, 2019 at 12:58
  • 1
    How are you getting floats? Can you show some code. Robotframework seems to go out of its way to treat most data as a string unless you ask it otherwise. Would you be able to post some very simple Roboframework code that shows the problem you're having?
    – anonygoose
    Sep 27, 2019 at 13:09
  • 1
    How? Show us some Robot code :) Sep 27, 2019 at 13:41

1 Answer 1

3

From the documentation I expect any "item" to be able to Convert To String: https://robotframework.org/robotframework/latest/libraries/BuiltIn.html#Convert%20To%20String

Maybe you should first Convert To Number, those seem Floats: https://robotframework.org/robotframework/latest/libraries/BuiltIn.html#Convert%20To%20Number

1
  • Yes, after some trial and runs I was able to convert float to String via convert to Number Sep 28, 2019 at 4:52

Not the answer you're looking for? Browse other questions tagged or ask your own question.