Object identification issue in Selenium testing

0
Hi All, I have been trying selenium testing for our application, I could able to automate the login but finding it difficult  when I try to do for any navigation menu since the IDs and classes in Menidx application changes dynamically. I am also trying to browse and upload the file, tried the following way driver.findElement(By.id("mxui_widget_Button_0")).sendKeys(“Path of the file”) but unable to fetch the file. Can anyone guide me on this? Your help will be really valuable to procced with the testing.  Thanks in advance.
asked
2 answers
1

Hello, 

Indeed, thats how Mendix works.

Most of the times, post deployment, we will end up with ID being changed.

Please read: https://docs.mendix.com/howto/testing/testing-mendix-applications-using-selenium-ide#5-locating-changing-a-test-target

Where Mendix already advise us about this particular case and also provides an alternate to use CSS based finding of elements. 

answered
0

Hello, 

In my case, this is what I see. Although I am not sure, about the random string generated in the class.

Just in case, if this is not suitable, then you can also look at the options of finding the proper DOM element and click that. There are lot of ways to find a DOM element.

answered