We have an hybrid application developed in Android which includes frequent transition from the Native context to the Webview context and vice versa.
Our Webview development framework is using React Libraries3 to improve app performance stats. Basic understanding on How React Works1 is that it creates a Virtual DOM using the real DOM and generates a dynamic class name corresponding to those in the javascript. The Diff Algorithm1 provides efficient way to differentiate the objects using those auto generated class names.
Now the problem(also stated here SO-339378983) faced by us is : Using Appium we are not able to access the elements from these webview using any of the findElementsBy method. The class name being only parameter visible to the ui-automator on which we could really rely on is changed by React on every fresh launch and install. Because of frequent updations in the application code, even in the worst case we wouldn't want to access the objects using the XPATH.
So cut short, though react webview gives us a good way of optimising the performance yet it has bought a concern in our plans to effectively automate the test cases written around the Webview accesses.
We are eager to know about any solutions that Appium community could provide to get access to these elements and help us automate the react developed webviews. Looking forward to some help. Open to all suggestions.
created
Jan '16
last reply
Feb '16
- 4
replies
- 2.3k
views
- 3
users
- 1
like
- 7
links