UI testing involves using the user interface to drive and test a system. Selenium is an open source tool that supports UI testing across many programming languages. It originated from projects at Thoughtworks and supports both the Selenium IDE Firefox add-on for recording and replaying tests, and the Selenium WebDriver API for programmatically controlling browsers. The document discusses UI testing concepts with Selenium like locators, commands, assertions, and page object patterns to help create more robust and maintainable tests.
3. What is UI testing?
a.k.a System Testing, Functional testing
Use UI to drive the system
All parts of system exercised
Ensure that UI behaves as expected
4. Testing through the UI
Pros
Ensure that system works as a whole
Easy regression testing
Cons
Expensive
Time consuming
5. Why use Selenium
Free
Open source
Supports Java, Ruby, .Net, Python, PHP & Perl
Portable
Combine with other tools
10. Concepts: Assert vs Verify
a.k.a hard or soft assertions
Different uses
Fail Assert = immediate test failure
Fail verify = continue to end of test
Use depends on test
14. Selenium IDE: Summary
Easy way to get started
Able to create suites of tests
Very good for quick smoke tests e.g navigation
Test can be exported to different languages
Limited to FireFox
Very data sensitive
Not usable from a CI server
15. Web Driver
Has native browser specific drivers
No server needed
Object Oriented API
HtmlUnit support
Support for Selenium RC
20. Page Object Pattern
Popular design pattern in testing
Abstracts a page
Encapsulates all operations
Helps prevent brittle tests
Page Object does not assert or verify