I have a user defined Enum class written in python. Wanted to use this class in robot framework to directly fetch the enums.
When i try to do - UserdefinedEnumClassName.EnumName inside a (.robot) file, it fails to resolve this statement and gives error.
(I have imported the python enum class in robot file)
What is the correct approach to fetch enums in robot file?
You didn’t provide any code example of what your trying to do and the the little you did provide doesn’t look like normal robot framework syntax.
So, I’ll suggest you start by looking at Creating test libraries and start with some really basic examples like building a class with a function that prints hello world and then call that as a keyword from robot framework, when you have that, then work towards what your trying to do. Everything you need is in the documentation I linked to, that’s where I learned it from.
Beyond that, the python source of most robot framework libraries are available (most on github) so you can peek into their code if your trying to figure out how they did something.
From looking at the python documentation for enum’s they look just like any other python class.