Our React app is using Material UI and instead of drop-down/select boxes, the original developers chose to go with a that contains an array of “MenuItem” from the MUI core.
Trying to automate the first page with two such drop downs, the record says it worked, but PlayBack fails when trying to select from the second “select” box.
Here’s a screenshot of the two elements on the page:
Here’s the playback screen image:
And here’s the code that was generated (I’m trying to automate through several such pages so have added only the first/relevant portions):
{
"CreationDate": "2018-10-25",
"Commands": [
{
"Command": "open",
"Target": "http://localhost:3000/create",
"Value": ""
},
{
"Command": "click",
"Target": "//*[@id=\"root\"]/div/div/div[2]/div/div/div[2]/div/div[1]/div/form/div[1]/div/div/div",
"Value": ""
},
{
"Command": "click",
"Target": "//*[@id=\"root\"]/div/div/div[2]/div/div/div[2]/div/div[1]/div/form/div[1]/div/div/div",
"Value": ""
},
{
"Command": "click",
"Target": "//*[@id=\"menu-\"]/div[2]/ul/li[4]",
"Value": ""
},
{
"Command": "click",
"Target": "//*[@id=\"menu-\"]/div[2]/ul/li[4]",
"Value": ""
},