
Explore end-to-end test automation with WebdriverIO, TypeScript, and Cucumber, plus API testing with super test, cross-browser testing in Chrome and Firefox, with Allure reporting and Winston for debugging.
This is just a quick demo on running basic test and seeing results in Allure reporter.
Dear All,
Some students have requested the presentation, so I’ve attached the course material as a PDF document. Please feel free to download it and use it as your handbook.
Best regards, and happy learning!
Install Node.js and set up VS Code to lay foundation for the WebDriver IO end-to-end test framework, and configure the WebDriver IO core engine with naming conventions and folder structure.
Begin with a precheck to see if node.js is installed, install from the official site, then perform a post-check verifying node -v and npm -v and locate the executable.
Install Visual Studio Code, the de facto code editor built with TypeScript, verify installation with code -V in cmd, download the latest version if needed, and check updates.
Create a simple Node.js project by setting up a workspace, initializing with npm, and configuring package.json; write a hello world script and run it with Node.js to verify the setup.
install WebDriver IO in the current workspace, set up TypeScript and module configuration, and configure the core WebDriver IO with cucumber for end-to-end testing.
Learn naming conventions for a WebdriverIO project: kebab case folders, Pascal case feature files, camelCase general files and variables, dot-separated page objects, and UPPER_CASE constants for readability.
Create a scalable folder structure for a WebdriverIO e2e framework, including config, data, debug, logs, resources, results, tests with features, step definitions, helpers, and page objects.
Explore essential VS Code extensions for the WebdriverIO e2e test framework, including cucumber support for feature file formatting, prettier for code formatting, and markdown preview with utilities such as gitignore.
Explore what comments are for: explain code and readability; see how the interpreter ignores them and they are not compiled. Learn three types: single-line, multi-line, and exclamation-mark based commands.
Explore variable definition and syntax in this session, declare and initialize variables with values, and print them using console.log, using examples like greeting and Hello world.
Master variable rules: start names with a letter, underscore, or dollar sign (not a number), avoid reserved keywords, respect case sensitivity, and declare multiple variables with undefined values in demos.
Master var, let, and const in JavaScript for automated tests, understanding var for declaration, let for block scope, and const for an initialized, read-only value that cannot be reassigned.
Discover how var, let, and const affect block scoping, see why let and const prevent outside access to inner variables, and learn how to avoid scope-related errors in tests.
Explore JavaScript data types, including string, number, boolean, undefined, null, bigint, symbol, and object, and learn how to create and represent them for test automation.
Explore how JavaScript literals represent strings, numbers, booleans, objects, arrays, null and undefined, and learn string concatenation, template literals, regex literals, and the typeof operator.
Explore how the typeof operator reveals runtime data types in a dynamic language, using template literals to print lowercase results for string, number, boolean, object, array, undefined, and null.
Explore data types and their forms in programming, including literals, variables, and expressions, with strings, booleans, concatenation, and basic operators, focusing on type and value.
Understand the six falsy values in JavaScript—false, undefined, null, 0, NaN, and empty string—and how they behave in boolean and numerical contexts to validate data.
Learn how to convert strings to numbers and numbers to strings in JavaScript using built-in global functions, the plus operator, and toString, with WebdriverIO examples.
Explore eight data types—seven primitives and one object—using the typeof operator. Learn primitive immutability, wrapper classes, and type conversion among number, string, boolean, and null/undefined.
Learn operator basics, including unary, binary, and ternary types, notation, and appearance, and understand how operators assign or compare values for testing results.
Learn the ten operators used in test automation with WebdriverIO, from assignment and arithmetic to comparison, string, ternary, unary, and relational operators, plus practical demo insights.
Explain the assignment operator, clarifying that a single equals sign performs assignment, not equality. Show right-to-left value flow and how += increments in loops.
Explore arithmetic operators in WebdriverIO: compute remainder with modulus, apply increment and decrement in loops, and convert strings to numbers using unary plus and the plus operator for concatenation.
Explore how comparison operators work in test automation, distinguishing equal to from assignment and using strict equality that considers value and type, noting not equal cases.
Explore logical operators like and, or, and not (&&, ||, !), and use them in conditional statements, default values, and string validation with type checks and length.
Explore the JavaScript logical OR operator (||) with a weekend check example, showing how Saturday or Sunday evaluates to true, and how left and right sides evaluate independently.
Explore how the not operator reverses booleans and combinations of truthy and falsy values, and learn to validate inputs using and, or, and not in real-world automation scenarios.
Explore how the logical or operator provides a default value in WebdriverIO end-to-end tests, using the auto operator syntax to fall back to the right-hand value when input is missing.
Explore the ternary operator, its condition ? value1 : value2 syntax, and how to nest it to conditionally set log levels for local, remote, and cloud environments.
Discover how strict mode in JavaScript prevents undeclared global variables and blocks using reserved keywords as identifiers. Learn how to enable it to enforce safer test scripts in WebdriverIO.
Explore the basics of conditional statements, including if and else syntax, assignment versus comparison operators, boolean evaluation, truthy/falsy values, and nested conditions with else if.
Demonstrate handling a random popup with a simple if condition in webdriverio, checking a boolean 'popup exists' to click ok or do nothing.
Learn how to use the not operator to detect falsy data (undefined, null, empty string, 0) and throw a validation error when data is not valid.
Explore use case 3 of the WebdriverIO e2e framework, implementing a simple if-else: read a file if it exists, otherwise create the file, with real-time flags.
Explore nested if conditions in end-to-end testing, where multiple exclusive branches execute a single block based on true conditions, with real-time scenarios like system errors, data validation, and retries.
Examine inner conditions with if..else blocks in a database use case to handle data outcomes. Explore no data, error states, and nested conditions that guide execution flow.
Learn to use if conditions inside loops to process collection elements in WebdriverIO. Break the loop when a specific condition, like six, is met, and inspect the log flow.
Explore switch case syntax in programming, learning how to match an expression against case labels, use break and default, and compare with if-else for browser driver setup and date-based actions.
This switch-case demo shows selecting a browser in a webdriverio end-to-end test framework using predefined values like chrome, firefox, and edge, with breaks and a default case.
Learn how loops iterate collections to find elements or apply actions to all items, and review common loop types such as for, for each, while, and do while.
This lecture demonstrates a simple standard for loop in C++ that prints numbers from zero to ten, with initialization, a semicolon separated condition, and proper increment.
Use a standard for loop to traverse a mixed array in JavaScript, check typeof element equals 'number', and accumulate the sum, handling break or continue as needed.
Master the standard for loop and break statement in browser automation by using get window handles to switch to a target window and breaking when the condition is met.
Explore how to use the forEach method to iterate over arrays by passing a callback function, including arrow function syntax, and accessing values, indices, and the array during iteration.
Master the while loop by defining an initial value, a boolean condition, and an increment to perform actions until the condition becomes true, including practical retry scenarios with maximum thresholds.
Learn how the for in and for of loops iterate over objects and arrays, accessing keys and values. Compare with for and for each method to apply appropriate iteration techniques.
Learn the basics of a string, a sequence of characters, and how to work with a zero-based index and the length property to access specific characters in code.
Explore the four ways to create strings in JavaScript—single quotes, double quotes, template literals, and the string object via new String—highlighting template literals for easy concatenation.
Learn to form strings with template literals by combining static text with dynamic parts like start date, end date, and account number to create contextual email subjects.
Compare strings in automated tests using full matches with equals and the triple equals operator, and partial matches with includes, starts with, and ends with.
Learn to extract substrings with the slice method on strings, using start and end indices (inclusive/exclusive) and negative indices; compare with substring and apply to year, month, date.
Master the string replace method and how to simulate replace all with regex, applying it to cases like extracting a file name, renaming extensions, replacing table names, and reformatting dates.
Learn how to extract substrings with the split method to separate date and time from a timestamp, split text by spaces, and isolate a file name from its extension.
Learn to extract a substring with indexOf and lastIndexOf by defining left and right boundaries, then use slice to obtain the application number from a log message.
Explain how the backslash acts as an escape character in strings. Show how the interpreter uses the next character to form a symbol or include a literal backslash or quote.
Learn how JavaScript functions perform tasks or return values, defined and called, with named declarations and anonymous expressions, plus parameters and optional returns.
Explore named functions in JavaScript, including returning values, actions without returns, and parameter versus argument usage. Delve into data types, undefined and NaN behavior, and TypeScript's role.
Explore anonymous function concepts, including function expressions, callbacks, and assigning unnamed functions to variables, plus how named functions retain scope inside their body and outside.
Explore function parameters, including default values, optional parameters, undefined inputs, and passing primitives, objects, arrays, or functions, with template literals and property access.
Explore rest parameters and the arguments object in functions, using the three-dot syntax to accept any number of arguments, access them by index or length, and sum them.
Master the return statement in functions for the WebdriverIO e2e test framework, returning primitives, expressions, or objects, and using anonymous functions or conditional early returns with falsy values.
Demonstrates self invoking function syntax by wrapping a function in parentheses with arguments and executing it immediately, useful for quick unit tests and visible console output.
Explore arrow functions in JavaScript, a shorter form of function expressions used in callbacks, with clear syntax, rules, and the binding of this explained.
Explore JavaScript's asynchronous nature by using callback functions and arrow functions with setTimeout, showing how A, B, and C execute out of order to illustrate non-sequential execution.
Create a .feature cucumber file linked to TypeScript step definitions, then implement a WebdriverIO end-to-end test that navigates a demo site, clicks make appointment, and checks login page display.
Identify and fix common webdriverio errors, including auto completion failures from json typos and misconfigured config paths; resolve step not defined issues using readme guidance.
Explore three test-running approaches in WebDriverIO: npx wdio commands, npm run script keys, and cucumber tag-based execution, including demo tagging and feature-level grouping.
Install git on Mac and explore options to use git from the command line, GUI, or integrated terminal to track changes and underpin our development workflow.
Install git on Windows using the standard command line installer, keep defaults, and use git bash to access the command line, check status, and manage local and remote repositories.
Create a GitHub account, set up a project repository with a readme, gitignore, and license, and rename the remote default branch from main to master before pushing local changes.
Initialize a local git repository with git init, check status with git status, and create a gitignore to exclude node_modules and dot env files, preparing for remote push.
Learn to configure git user settings, commit changes locally, connect to a remote repository, create and switch branches, push to origin, and set up tracking for seamless future pushes.
Learn selector strategy in Webdriver IO: use CSS and XPath, query elements with $ and $$, and locate by id, class, tag, or attribute, including dynamic partial matches.
Learn practical selector strategies in WebdriverIO, covering css selectors (id, class, tag, attribute), text-based and XPath locators, contains, starts with, ends with, dynamic templates, and parent-child navigation.
Master handling dropdowns in WebdriverIO: identify the select element, determine the default option, and select by attribute, visible text, or index; retrieve all options and validate selections.
Learn to interact with checkboxes using WebdriverIO: select and unselect options, assert selections, handle multiple checkboxes with array locators, and leverage DOM, XPath, and CSS selectors.
Explore handling multiple browser windows in WebdriverIO by using window handles, get title, switch to target window by title, print the Elemental Selenium header, and return to the parent window.
Learn to handle JavaScript alerts in WebdriverIO, including alert, confirm, and prompt, using browser commands like is alert open, accept alert, dismiss alert, and get alert text.
Upload files in WebdriverIO by targeting an input tag, using addValue to set the file path, and building an absolute path with process.cwd() for reliable uploads.
Master frames and iframes in WebdriverIO by switching to a frame, interacting with its elements, and returning to the parent frame. Compare setValue and addValue for typing inside frames.
Master basic scrolling in web automation with WebdriverIO by using scroll into view to locate elements, navigate sections like Amazon bestsellers, and tailor the scroll position with optional flags.
Iterate over multiple elements to validate six products and their prices on a demo app. Build end-to-end tests with WebdriverIO, Cucumber, and TypeScript using feature files.
Iterates over multiple product prices, collects price strings, converts to numbers by removing the dollar sign, and asserts all prices are valid using map and filter.
Learn to interact with web tables using WebdriverIO: identify rows and columns, access cells by row/column, and convert the table data from thead and tbody into an array of objects.
Learn to extract table data with WebdriverIO by filtering rows, retrieving single rows or columns, handling empty results, and selecting records based on values like first name or due amount.
Learn to automate scrolling in webdriverio using window.scrollBy and scrollTo, including vertical and horizontal directions, smooth versus auto behavior, and scrolling into view for elements.
Explore how hard and dynamic waits work across session, browser, connection, and element levels in WebdriverIO, and learn to configure timeouts for your framework and cucumber or mocha tests.
Learn to implement dynamic waits with waitUntil for browser and elements, waiting for title changes, element states, or text field loads, with configurable timeout, interval, and timeout message.
Learn how to use reload sessions, refresh, and back and forward navigation in WebdriverIO to handle multi-user workflows, retries, and stateful applications within a single test execution.
Master debugging WDIO sessions by using the debug command to pause, adjust framework timeouts, inspect elements with repl, and diagnose timeouts or assertion errors.
Learn to use repl to quickly spin up the browser from the command line, interact with the app, log in, inspect elements, and pinpoint failure points in lengthy end-to-end tests.
Learn how to configure browser capabilities and arguments to overcome browser-specific challenges, including SSL and proxy issues, and apply chrome options across cross-browser testing using the WebDriver protocol.
What's unique about this course?
Built completely based on REAL TIME PROJECT IMPLEMENTATION & WORKING EXPERIENCE of automating E2E tests
Integrated framework with Web + API + DB + File handling and more with page object design pattern
Using this framework one can confidently build an E2E test framework from ground zero
Uses Async mode which has LONG TERM SUPPORT
Cucumber(BDD), Cross-browser testing and GitHub Actions and more
Logger and global reporter that makes easier to debug and fix tests and produce accurate test report
Tips and tricks to overcome different project implementation challenges
Why Webdriverio?
It's becoming common to adopt to a Node.js based test framework in many organisations due to having "one team one language" concept where most of the modern web and backend services are built using JavaScript and Node.js and therefore there is a flexibility to extend unit tests and integrate with CI/CD pipeline seamlessly - For all these reasons, Webdriver IO is a great choice for automating integration/E2E tests.
WebdriverIO(also known as WDIO) is the established test framework for Node.js. It has got powerful runner that supports Cucumber, Mocha and Jasmine and loaded with many features that makes easier to use.
WDIO can be run on WebDriver or Chrome DevTools Protocol - this means it has a full control over all browser elements to interact with. It is highly extendable that makes easier to automate E2E tests, not just web.
Is automating web application just enough?
It’s hard to find a project that just automates only web applications, the scope of automation is widen to integrate Web with API, database and files and even more. If this is what you are looking for, you have landed in the right place. This course is having everything you need to know to build an highly extensible integrated framework that can accomodate different applications components.
What topics are covered? (All that you need to know work in real projects):
Introduction
Installation and project set up
Run first webdriverio test
Git Integration
Locator Strategy
Handling Web Elements
Web Advanced Interactions
Browser args and capabilities - USER STORY starts
Run Headless
Run Parallel
Managing different environments
Cucumber Integration
Cucumber Advanced integration
Set up logger
Reporter
Exception handling
Set up Global Reporter
Framework Building Blocks & Page Object Model
API Testing Integration [ADDONS:You are start building helpers from here]
Build E2E Tests
Cross Browser Testing
CI Integration
DB Integration
JavaScript for beginners (basics)
Grid for cross-browser testing (upcoming)
This course is designed such a way that anyone who wants to learn or implement Node.js based E2E test framework in their current role as a QA engineer or Automation tester can build it from scratch.