Hello,
I am passing a multilayer hash over the remote perl library connection and am having some issues parsing data from it. I am using the built in collections library to perform operations against the returned dictionary and It appears that only the outer keys are being read when performing these related functions.
11:06:25.421 INFO Dictionary size is 2 and it contains following items:
content: {'data': {'read_only': 0, 'description': '', 'name': 'test234'}, 'model': 'data', 'id': 92, 'uri': '/api/2.9/data/92'}
status: 201
As you can see above, the content key is the outer key of the multilayer hash. It reads like this:
$VAR1 = {
'content' => {
'data' => {
'name' => 'test234',
'description' => undef,
'read_only' => 0
},
'model' => 'data',
'id' => 92,
'uri' => '/api/2.9/data/92'
}
};
'content' is the outer key with a nested hash within it (data) and 3 additional keys (model,id and uri). If I try the following against the 'status' key, it works fine:
${status} Get From Dictionary ${ret} status
Returned data:
Running against the 'content' key returns:
{'data': {'read_only': 0, 'description': '', 'name': 'test234'}, 'model': 'data',
'id': 92, 'uri': '/api/2.9/data/92'}
However, I can't seem to pull any of the values from the nested data key. I tried assigning the key to a variable (like the above example) and using the 'Should Contain' keyword, but that failed. Any idea on what I need to do in order to lookup the values form the nested key(s)?
Thanks,
Shawn