课程: Mobile Testing with Appium

今天就学习课程吧!

今天就开通帐号,24,700 门业界名师课程任您挑!

Locator strategies and finding elements: Theory

Locator strategies and finding elements: Theory - Selenium教程

课程: Mobile Testing with Appium

Locator strategies and finding elements: Theory

- [Instructor] Once you have an Appium session running, you can use it to automate your mobile app for the purpose of testing. Of course, you'll want to have an idea of what you want to test first. For example, let's say you want to test the login functionality of your app works. How would you do this manually? Well, you'd navigate to the point in your app where there are text input fields for usernmae and password entry and enter appropriate text in those fields. Then you'd look for a login button of some kind and tap it. Finally, you'd look at the resulting screen and make sure the login was successful, that there were no error messages, et cetera. When writing Appium tests, we follow exactly the same process. We just turn each of these manual steps into code. The manual step often goes unnoticed by us as humans, but is extremely important. We have to actually locate the UI element we want to interact with. In this case, we have to find the username field before we can enter our…

内容