Duration
2 days
Overview
This Selenium training, tailored to experienced developers and testers with substantial HTML and Java experience, teaches attendees how to automate testing of web application interfaces using Selenium with Java and Cucumber. Selenium is a testing framework for web applications, Java is a programming language that can be used to automate Selenium, and Cucumber is a software tool for running automated acceptance tests.
Course Objectives
- Create test scripts using Selenium Builder
- Know how to use the online documentation and the WebDriver API
- Create, debug and maintain Selenium test scripts
- Understand and be able to communicate the concepts necessary for testing with Selenium
- Interact and verify web elements using selectors
- Refactor existing scripts to leverage the Page Object Model
- Use Behavior Driven Development techniques
Who Should Attend
Java Developer
Prerequisite
- Basic knowledge of Java
- Basic understanding of programming is helpful
- Understanding of web pages
- Working computer with Firefox or Chrome browser
- Familiar with software testing
Module 1: Introduction to Testing and Selenium Automation
- What is Testing?
- What is Automation
- Introduction to Selenium
- Selenium Automation
Module 2: Work with Selenium
- Installing Selenium IDE
- Record and Run with
- Modifying Test Data
- Exporting Selenium IDE to Java Code
- Preparing the Test Environment
- Getting started with Java and IntelliJ
Module 3: Automating Action with Selenium Webdriver
- Creating the Login Test Outline
- Opening a Web Browser with Selenium
- Understanding HTML and the DOM
- Finding Elements Using Chrome
- Stimulating User Action on Web Page
- CApturing Text on a Page, Title and Closing
Module 4: Find Elements on a Web Page
- Overview of New Account Applicant
- Preparing Environment with Firefox and Firebug
- Writing the Test Outline and Opening a Firefox Browser
- Item Locator: By LinkText, By Name, By ID
- Item Locator: By XPath (Relative and Absolute)
- Item Locator: By CSS Selector
- Interacting with Form Elements
- Completing the New Account Application
Module 5: Testing Frameworks and Reporting Methods
- Introduction to JUnit Framework
- Assertions: Generate Test Results
- Annotations: Guiding the Test Flow
- Class Variables within a Framework
- Installing TestNG Framework in IntelliJ
- Setting up a TestNG Framework
- Preparing a Test Suite
- Managing an XML Test Suite
Module 6: Build a Complete Data-Driven Framework
- The CSV Reader Class
- JUnit @Parameters
- Data-Driven Testing with JUnit and CSV
- The Excel Reader Class
- Data-Driven Testing with TestNG and Excel
Module 7: Page Object Models
- What is the Page Object Model?
- Setting up a Test with POM
- Implementing the Login Page Class
- Implementing the Dashboard Page Class
- Writing a Test with Page Objects
- Enhance POM with PageFactory
Module 8: Behavior-Driven Development with Cucumber
- What is BDD and Cucumber?
- Preparing the Cucumber Environment
- Writing a Feature File in Gherkin
- Writing Step Definition Class
- Writing the TestRunner with JUnit
- Implementing Step Definitions with Selenium
- Enhancing Feature Files with Data Tables
- Parameterizing Data into Step Definitions
- Executing Tests and Fixes
Programme scope, delivery arrangements and suitability are confirmed during enquiry.