How to access Suite metadata values using robot.api


I am trying to improve our results processing and I encountered an issue I am not sure how to solve.
To automatically send an email with suite results and other relevant information, I need to dig out the information first. I need to access the Suite metadata from ***Settings*** section. However, using the robot.api, I only accessed the metadata names, not their values.

There’s the following line in the output.xml
<meta name="test_branch">my_testing_branch</meta>

Using Python & robot.api
for metadata in ExecutionResult(“output.xml”).suite.metadata:

Is there a way to access the value of the metadata named test_branch, which is my_testing_branch using robot.api (RF 5.0.1)?

I bet everyone is familiar with the situation when you feel like you really should ask a question, but as soon as you finish the question, you realize what the answer is.

I simply had to change the approach to the data:

metadata = ExecutionResult("output.xml").suite.metadata
for key, value in metadata.items():
    print(key, value)

I hope this will help at least one more RF colleague :blush: