Software Testing and Automation (Unit-5)
Software Testing and Automation (Unit-5)
• Automated Testing is a technique where the Tester writes scripts on their own and
uses suitable Software or Automation Tool to test the software. It allows for
executing repetitive tasks without the intervention of a Manual Tester.
• Automated testing is the application of software tools to automate a human-driven
manual process of reviewing and validating a software product. Most modern agile
and DevOps software projects now include automated testing from inception.
5.2 AUTOMATED TESTING OF WEB APPLICATIONS
• More reliable
• Improved quality and confidence
• Reduced cost
• Increased speed
CHALLENGES
• Selenium
• TestNG
• Cypress
• Appium
• LoadRunner
• Testcafe
FACTORS TO CONSIDER FOR SELECTING RIGHT
AUTOMATION TOOL
• Application type and technology
• Programming language
• Learning curve
• Cost and licensing
• Team collaboration
• Testing requirements
3.3 SELENIUM
• Anything that is present on the web page is a WebElement such as text box,
button, input field, dropdown menu , links etc.
• WebElement represents an HTML element.
TYPES OF WEB ELEMENTS SELENIUM
1. Edit box
2. Link
3. Button
4. Image, image link, an image button
5. Text area
6. Checkbox
7. Radio button
8. Dropdown list
LOCATING WEB ELEMENTS USING VARIOUS
STRATEGIES
• Defined as the process of finding the HTML elements on a web page that it
wants to interact.
• Selenium provides methods and APIs to locate, interact and validate
behavior of these web elements during automated testing.
• Selenium provides functionalities that help in locating the element on a
web page. It makes use of element locators.
• Operations performed on the Selenium WebElements
• In order to access WebElements, we need to perform a set of operations starting with
browser actions until the operations are performed on frames.
• Operations performed on the browser
• Launch the browser
• Navigate to particular web page
• Close the current browser
• Close all browsers opened by WebDriver during execution
• Maximize browser
• Refresh the browser
• Operations on the web page
• Get page title
• Get page URL
• Operations on link
• Click the link
• Return the link name
• Operations on text area
• Return or capture the messages from the web page
• Operations on checkbox
• Select the checkbox
• Unselect the checkbox