Koding Tree

Koding Tree

Software Training Institute

Koding Tree

Software Training Institute

Our Programs

Selenium Automation Testing

Koding Tree offers two comprehensive programs: a Selenium Course and a Java Course, designed to take you from core programming fundamentals to advanced concepts like system architecture and multithreading.

Java course

Java Environment & Architecture

  • JDK vs JRE vs JVM – what each component does and why all three matter
  • How Java achieves platform independence – write once, run anywhere via bytecode
  • Installing JDK and setting up Eclipse IDE for Java development
  • Configuring JAVA_HOME and verifying with java -version

First Java Program

  • Structure of a Java class – class keyword, public static void main(String[] args)
  • System.out.println() and System.out.print() – printing output to the console
  • Compiling with javac and running with java from the command line
  • Organising classes into packages – naming conventions and folder structure

Primitive Data Types

  • Variable declaration and assignment – naming rules and conventions
  • Integer types: byte, short, int, long – size and valid range of each
  • Floating-point types: float vs double – precision and when to use each
  • char – single Unicode character, stored as a 16-bit number
  • booleantrue / false only; used in all conditions and loops
  • String – non-primitive reference type; immutable character sequence

Type Conversion & Constants

  • final keyword – declaring a constant that cannot be reassigned
  • Widening (implicit) conversion – Java automatically promotes smaller types to larger
  • Narrowing (explicit) casting – (int) 3.14 – data loss risk and when it is acceptable

Operator Types

  • Arithmetic: +, -, *, /, % (modulus) – integer division behaviour
  • Increment / Decrement: ++, -- – prefix vs postfix difference
  • Relational: ==, !=, >, <, >=, <= – always return boolean
  • Logical: && (AND), || (OR), ! (NOT) – short-circuit evaluation
  • Assignment shortcuts: +=, -=, *=, /=, %=
  • Ternary operator: condition ? valueIfTrue : valueIfFalse

Conditional Statements

  • if, else, else if ladder – single and multi-branch decision making
  • Nested if – conditions inside conditions for complex logic
  • switch statement – case, default, and break; fall-through behaviour
  • Scanner class – nextInt(), nextLine(), nextDouble() for reading user input

Loop Types & Control Statements

  • for loop – initialisation, condition, update; most common for counted iterations
  • while loop – condition checked before each iteration; runs zero or more times
  • do-while loop – condition checked after; always executes at least once
  • break – immediately exits the current loop
  • continue – skips the rest of the current iteration and moves to the next
  • Nested loops – outer loop controls rows, inner loop controls columns

Pattern Printing

  • Star (*) patterns – right triangle, left triangle, pyramid, diamond
  • Number patterns – sequential, mirrored, and Pascal’s triangle style
  • Analysing patterns – how to break any design into row count and column logic

1D Arrays

  • Array declaration: int[] arr = new int[5] – fixed size, zero-indexed
  • Initialisation at declaration: int[] arr = {10, 20, 30}
  • arr.length – getting the size of an array
  • Iterating with for loop and enhanced for-each loop
  • Common operations: finding max/min, sum, average, reverse, search
  • Arrays.sort() – sorting in ascending order

2D Arrays

  • Declaration: int[][] matrix = new int[rows][cols] – row-major storage
  • Nested loops to traverse rows and columns of a 2D array
  • Matrix operations – addition, transpose, diagonal sum

Defining & Using Methods

  • Method signature: access modifier, return type, method name, parameter list
  • Calling a method – passing arguments, receiving return values
  • void methods vs methods with a return type
  • static methods – called on the class directly without creating an object
  • Instance (non-static) methods – require an object to call
  • Method overloading – same name, different parameter types or count
  • Writing generic, reusable utility methods for common operations

Classes & Objects

  • Class as a blueprint – instance variables (fields) and instance methods
  • Creating objects: ClassName obj = new ClassName()
  • Default constructor – auto-provided by Java when no constructor is defined
  • Parameterised constructor – initialising objects with values at creation time
  • this keyword – resolving naming conflicts between parameters and instance fields

static & final Members

  • static variable – one copy shared across all instances of a class
  • static method – belongs to the class, not to any object
  • final variable – constant; must be assigned exactly once
  • final method – cannot be overridden by a subclass
  • final class – cannot be extended (e.g., String is a final class)

Inheritance

  • extends keyword – child class inherits all non-private members of the parent
  • super keyword – calling the parent class constructor or methods
  • Types: single inheritance, multilevel inheritance, hierarchical inheritance
  • Java does not support multiple class inheritance – why, and how interfaces solve this

Encapsulation & Access Modifiers

  • private, protected, public, package-private – scope of each
  • Encapsulation pattern – private fields with public getter and setter methods
  • Why encapsulation prevents invalid state and makes code easier to maintain
  • Method overloading – same method name, different parameter signature

Method Overriding & Runtime Polymorphism

  • Method overriding – child class provides its own implementation of a parent method
  • @Override annotation – compile-time check that overriding is valid
  • Runtime (dynamic) polymorphism – method resolved at runtime based on actual object type
  • Overloading vs overriding – compile-time vs runtime; key differences interviewers test

Object Type Casting

  • Upcasting – implicit; Animal a = new Dog() – always safe
  • Downcasting – explicit; Dog d = (Dog) a – requires instanceof check
  • instanceof operator – safely checking type before casting

Interfaces

  • interface keyword – defines a contract of method signatures without implementation
  • implements keyword – a class agrees to provide all interface methods
  • Interface methods are implicitly public abstract, fields are public static final
  • A class can implement multiple interfaces – Java’s answer to multiple inheritance

Abstract Classes

  • abstract class – cannot be instantiated; must be subclassed
  • abstract method – declared without a body; subclass must provide implementation
  • Can contain both abstract methods and fully implemented (concrete) methods
  • Interface vs abstract class – when to use each; key differences for interviews

String Class & Key Methods

  • String is immutable – every operation creates a new object in the String Pool
  • length(), charAt(int), indexOf(String), lastIndexOf()
  • substring(int start), substring(int start, int end)
  • toUpperCase(), toLowerCase(), trim()
  • replace(), contains(), startsWith(), endsWith()
  • equals() vs equalsIgnoreCase() vs == – why == compares references, not content
  • split(String regex), join(), toCharArray()

StringBuilder & StringBuffer

  • StringBuilder – mutable, not thread-safe, faster for single-threaded use
  • append(), insert(), delete(), reverse(), toString()
  • StringBuffer – mutable, thread-safe, used in multi-threaded programs
  • String vs StringBuilder vs StringBuffer – performance and thread-safety trade-offs

List – Ordered, Allows Duplicates

  • ArrayList – dynamic array; fast random access; allows duplicates; maintains insertion order
  • LinkedList – doubly-linked list; fast add/remove at ends; slower random access
  • Common methods: add(), get(int), remove(), size(), contains(), set()
  • Iterating with for-each and Iterator

Set – No Duplicates

  • HashSet – no duplicates, no guaranteed order; backed by a hash table
  • LinkedHashSet – no duplicates, preserves insertion order
  • TreeSet – no duplicates, elements stored in natural sorted order

Queue & Stack

  • Queue interface – FIFO; offer(), poll(), peek()
  • Stack – LIFO; push(), pop(), peek()
  • Vector – legacy thread-safe version of ArrayList

Map – Key-Value Pairs

  • HashMap – key-value pairs, no guaranteed order, allows one null key
  • LinkedHashMap – key-value pairs, preserves insertion order
  • Common methods: put(), get(), remove(), containsKey(), keySet(), values()

Sorting & Iteration

  • Comparable interface – compareTo() for natural ordering inside the class
  • Comparator interface – compare() for custom ordering defined outside the class
  • Collections.sort(list) and Collections.sort(list, comparator)
  • IteratorhasNext() and next() for safe manual traversal

Exception Handling Mechanism

  • What is an exception – an unexpected event that disrupts normal program execution
  • Checked vs unchecked exceptions – compile-time vs runtime
  • try block – code that may throw an exception
  • catch (ExceptionType e) – handling a specific exception type
  • Multiple catch blocks – handling different exception types separately
  • finally block – always executes; used for resource cleanup (closing files, connections)
  • throw keyword – manually throwing an exception from your code
  • throws keyword – declaring that a method may throw a checked exception
  • Common exceptions:
    • NullPointerException
    • ArrayIndexOutOfBoundsException
    • NumberFormatException
    • ArithmeticException

List – Ordered, Allows Duplicates

  • ArrayList – dynamic array; fast random access; allows duplicates; maintains insertion order
  • LinkedList – doubly-linked list; fast add/remove at ends; slower random access
  • Common methods: add(), get(int), remove(), size(), contains(), set()
  • Iterating with for-each and Iterator

Set – No Duplicates

  • HashSet – no duplicates, no guaranteed order; backed by a hash table
  • LinkedHashSet – no duplicates, preserves insertion order
  • TreeSet – no duplicates, elements stored in natural sorted order

Queue & Stack

  • Queue interface – FIFO; offer(), poll(), peek()
  • Stack – LIFO; push(), pop(), peek()
  • Vector – legacy thread-safe version of ArrayList

Map – Key-Value Pairs

  • HashMap – key-value pairs, no guaranteed order, allows one null key
  • LinkedHashMap – key-value pairs, preserves insertion order
  • Common methods: put(), get(), remove(), containsKey(), keySet(), values()

Sorting & Iteration

  • Comparable interface – compareTo() for natural ordering inside the class
  • Comparator interface – compare() for custom ordering defined outside the class
  • Collections.sort(list) and Collections.sort(list, comparator)
  • IteratorhasNext() and next() for safe manual traversal

Selenium course

Tools & Setup

  • Installing Java JDK, Eclipse IDE, and configuring environment variables
  • Creating a Maven project and understanding pom.xml structure
  • Adding Selenium WebDriver dependency via Maven Central
  • Setting up ChromeDriver, GeckoDriver (Firefox), and EdgeDriver

WebDriver Fundamentals

  • Understanding the Selenium architecture – how WebDriver communicates with browsers
  • Instantiating WebDriver for Chrome, Firefox, and Edge browsers
  • Writing and running your first automation script end-to-end
  • Understanding the difference between Selenium 3 and Selenium 4

WebDriver Browser Commands

  • driver.get() and driver.navigate().to() – loading URLs
  • navigate().back(), navigate().forward(), navigate().refresh()
  • driver.manage().window().maximize(), setSize(), setPosition()
  • driver.getTitle() and driver.getCurrentUrl() for page verification
  • driver.quit() vs driver.close() – when to use each

💡 Locators are how your script finds elements on a page. Mastering all 8 strategies means you can automate any website, no matter how it is built.


All 8 Locator Types

  • By.id – fastest and most reliable when available
  • By.name – using the HTML name attribute
  • By.className – single CSS class targeting
  • By.tagName – selecting by HTML element type
  • By.linkText – exact anchor text matching
  • By.partialLinkText – partial anchor text matching
  • By.cssSelector – powerful CSS-based targeting
  • By.xpath – most flexible, works anywhere in the DOM

💡 CSS Selectors and XPath are the two most powerful locator types. Knowing both in depth allows you to find any element — even in the most complex web pages.


CSS Selector Techniques

  • Tag, ID, class, and attribute-based CSS selectors
  • Combining multiple attributes: input[type='text'][name='email']
  • Child and descendant selectors, sibling selectors
  • :nth-child(), ^=, $=, *= – starts-with, ends-with, contains patterns

XPath Techniques

  • Absolute XPath vs Relative XPath – differences and when to use each
  • XPath with attributes: //tag[@attribute='value']
  • contains(), starts-with(), text() functions
  • XPath axes: parent, child, following-sibling, preceding-sibling, ancestor
  • Grouping and index-based XPath: (//tag)[2]
  • AND / OR logical operators in XPath expressions

💡 Once you find an element, you need to interact with it – type, click, read values. These are the core actions every automation script performs.


WebElement Action Methods

  • sendKeys() – typing into text fields and input boxes
  • click() – clicking buttons, links, checkboxes, and radio buttons
  • clear() – clearing existing text from input fields
  • submit() – submitting forms directly

WebElement Property Methods

  • isSelected() – checking state of checkboxes and radio buttons
  • isEnabled() – verifying if a field or button is active
  • isDisplayed() – checking if an element is visible on screen
  • getText() – reading the visible text of any element
  • getAttribute() – reading any HTML attribute value
  • getCssValue() – reading applied CSS property values

💡 Many modern websites require mouse gestures and keyboard combos that a simple click cannot handle. The Actions class and screenshot tools cover exactly these scenarios.


Actions Class – Advanced Mouse & Keyboard

  • moveToElement() – hovering over menus and tooltips
  • doubleClick() and contextClick() (right-click)
  • dragAndDrop() and dragAndDropBy()
  • Keyboard actions: keyDown(Keys.SHIFT), keyUp(), sendKeys(Keys.ENTER)
  • Scroll actions using scrollToElement() and scrollByAmount() (Selenium 4)
  • build().perform() – chaining and executing action sequences

Capturing Screenshots

  • TakesScreenshot interface – full-page screenshot on test failure
  • Element-level screenshot using WebElement.getScreenshotAs()
  • AShot library – for full-page scrolling screenshots
  • JavaScript Executor-based screenshot approach

💡 Real applications open pop-ups, new tabs, and embed content in frames. Knowing how to switch between them keeps your scripts from getting stuck.


Window & Tab Handling

  • driver.getWindowHandle() – capturing the current window reference
  • driver.getWindowHandles() – getting all open window/tab references
  • driver.switchTo().window(handle) – switching between windows and tabs
  • Opening a new tab using Selenium 4’s newWindow(WindowType.TAB)
  • Closing child windows and returning to the parent window

Frame & Alert Handling

  • driver.switchTo().frame() – switching by index, name, or WebElement
  • driver.switchTo().defaultContent() – returning to the main page
  • driver.switchTo().alert() – handling JavaScript alerts and confirms
  • alert.accept(), alert.dismiss(), and alert.sendKeys()

💡 Dropdowns and lists of elements appear in almost every real application. These tools give you precise control over selecting values and working with element collections.


Select Class – Dropdown Handling

  • Importing and using the Select class from Selenium support
  • selectByVisibleText(), selectByValue(), selectByIndex()
  • getOptions(), getAllSelectedOptions(), getFirstSelectedOption()
  • Handling multi-select dropdowns with deselectAll()

Working with Multiple Elements

  • driver.findElements() – returning a List<WebElement>
  • Iterating over element lists to validate data or perform bulk actions
  • Counting elements, checking presence, filtering by state

💡 Timing issues cause most automation failures. Proper synchronization makes your scripts reliable — even on slow networks or dynamic pages that load asynchronously.


Wait Types

  • Thread.sleep() – static wait (why it should be avoided in real scripts)
  • driver.manage().timeouts().implicitlyWait() – global element search timeout
  • WebDriverWait with ExpectedConditions – explicit conditional waits
  • Key conditions:
    • visibilityOfElementLocated
    • elementToBeClickable
    • textToBePresentInElement
    • alertIsPresent
  • FluentWait – polling interval, custom timeout, ignoring exceptions
  • Choosing the right wait strategy for different application behaviours

💡 POM is the industry-standard way to organise automation code. It separates locators from test logic — making scripts easier to maintain when the UI changes.


POM Architecture

  • Why POM exists – separation of page logic from test logic
  • Creating Page classes with locators and action methods
  • @FindBy annotation – declaring locators declaratively
  • PageFactory.initElements(driver, this) – initialising page elements
  • Structuring a multi-page project: LoginPage, HomePage, CartPage, etc.

Common Issues & Fixes

  • Understanding and handling StaleElementReferenceException
  • Lazy initialisation vs eager initialisation of page elements
  • Reusing page objects across multiple test classes

💡 TestNG is the test management backbone of most Selenium projects. It controls the order, grouping, and reporting of your tests — making your suite production-quality.


TestNG Annotations & Configuration

  • Core annotations: @Test, @BeforeMethod, @AfterMethod, @BeforeClass, @AfterClass, @BeforeSuite, @AfterSuite
  • Test grouping with groups attribute – running smoke vs regression sets
  • Parameterisation using @Parameters and testng.xml configuration
  • Data-driven testing using @DataProvider
  • Parallel test execution – configuring thread count in testng.xml
  • Test priority, dependency (dependsOnMethods), and enabled flag
  • Custom logging using Reporter.log() inside test methods

Assertions

  • Hard assertions with Assert – test stops immediately on failure
  • Soft assertions with SoftAssert – collect all failures, report at end
  • Common assertion methods: assertEquals, assertTrue, assertFalse, assertNull, assertNotNull
  • Choosing between hard and soft assertions based on test scenario

💡 Data-driven testing lets one script run across hundreds of input combinations stored in an Excel sheet — a standard practice in enterprise QA teams.


Apache POI – Excel Integration

  • Adding Apache POI dependency to pom.xml for .xlsx support
  • XSSFWorkbook, XSSFSheet, XSSFRow, XSSFCell – reading the Excel object hierarchy
  • Reading test data row-by-row from an Excel file into test scripts
  • Handling different cell types: String, Numeric, Boolean, Formula
  • Writing test results (Pass/Fail) back into the Excel sheet
  • Building a reusable ExcelUtils utility class for the framework

 

💡 This module brings everything together into a production-level framework — the kind you will actually work with inside a software company.


Framework Design (AFW)

  • Recommended folder structure: src/main for utilities, src/test for test scripts
  • Building a BaseTest class – centralised driver initialisation and teardown
  • Integrating POM page classes, Excel utilities, and TestNG configuration
  • Maven Surefire Plugin – triggering test suites from command line
  • Version control with GitHub – pushing the project, branching basics

Selenium Grid & Cross-Browser Testing

  • Selenium Grid architecture – Hub and Node setup for distributed execution
  • RemoteWebDriver – running tests on remote machines and browsers
  • Cloud-based grid execution using SauceLabs
  • Configuring browser capabilities for parallel cross-browser runs

Jenkins CI/CD Integration

  • Installing and configuring Jenkins for a Java/Maven project
  • Creating a Jenkins job linked to a GitHub repository
  • Scheduling automated test runs using cron-style build triggers
  • Viewing TestNG reports and build history inside Jenkins dashboard

Exception Handling Mechanism

  • What is an exception – an unexpected event that disrupts normal program execution
  • Checked vs unchecked exceptions – compile-time vs runtime
  • try block – code that may throw an exception
  • catch (ExceptionType e) – handling a specific exception type
  • Multiple catch blocks – handling different exception types separately
  • finally block – always executes; used for resource cleanup (closing files, connections)
  • throw keyword – manually throwing an exception from your code
  • throws keyword – declaring that a method may throw a checked exception
  • Common exceptions:
    • NullPointerException
    • ArrayIndexOutOfBoundsException
    • NumberFormatException
    • ArithmeticException

List – Ordered, Allows Duplicates

  • ArrayList – dynamic array; fast random access; allows duplicates; maintains insertion order
  • LinkedList – doubly-linked list; fast add/remove at ends; slower random access
  • Common methods: add(), get(int), remove(), size(), contains(), set()
  • Iterating with for-each and Iterator

Set – No Duplicates

  • HashSet – no duplicates, no guaranteed order; backed by a hash table
  • LinkedHashSet – no duplicates, preserves insertion order
  • TreeSet – no duplicates, elements stored in natural sorted order

Queue & Stack

  • Queue interface – FIFO; offer(), poll(), peek()
  • Stack – LIFO; push(), pop(), peek()
  • Vector – legacy thread-safe version of ArrayList

Map – Key-Value Pairs

  • HashMap – key-value pairs, no guaranteed order, allows one null key
  • LinkedHashMap – key-value pairs, preserves insertion order
  • Common methods: put(), get(), remove(), containsKey(), keySet(), values()

Sorting & Iteration

  • Comparable interface – compareTo() for natural ordering inside the class
  • Comparator interface – compare() for custom ordering defined outside the class
  • Collections.sort(list) and Collections.sort(list, comparator)
  • IteratorhasNext() and next() for safe manual traversal
Our Programs

Selenium Automation Testing

Koding Tree offers two comprehensive programs: a Selenium Course and a Java Course, designed to take you from core programming fundamentals to advanced concepts like system architecture and multithreading.

Java course

Java Environment & Architecture

  • JDK vs JRE vs JVM – what each component does and why all three matter
  • How Java achieves platform independence – write once, run anywhere via bytecode
  • Installing JDK and setting up Eclipse IDE for Java development
  • Configuring JAVA_HOME and verifying with java -version

First Java Program

  • Structure of a Java class – class keyword, public static void main(String[] args)
  • System.out.println() and System.out.print() – printing output to the console
  • Compiling with javac and running with java from the command line
  • Organising classes into packages – naming conventions and folder structure

Primitive Data Types

  • Variable declaration and assignment – naming rules and conventions
  • Integer types: byte, short, int, long – size and valid range of each
  • Floating-point types: float vs double – precision and when to use each
  • char – single Unicode character, stored as a 16-bit number
  • booleantrue / false only; used in all conditions and loops
  • String – non-primitive reference type; immutable character sequence

Type Conversion & Constants

  • final keyword – declaring a constant that cannot be reassigned
  • Widening (implicit) conversion – Java automatically promotes smaller types to larger
  • Narrowing (explicit) casting – (int) 3.14 – data loss risk and when it is acceptable

Operator Types

  • Arithmetic: +, -, *, /, % (modulus) – integer division behaviour
  • Increment / Decrement: ++, -- – prefix vs postfix difference
  • Relational: ==, !=, >, <, >=, <= – always return boolean
  • Logical: && (AND), || (OR), ! (NOT) – short-circuit evaluation
  • Assignment shortcuts: +=, -=, *=, /=, %=
  • Ternary operator: condition ? valueIfTrue : valueIfFalse

Conditional Statements

  • if, else, else if ladder – single and multi-branch decision making
  • Nested if – conditions inside conditions for complex logic
  • switch statement – case, default, and break; fall-through behaviour
  • Scanner class – nextInt(), nextLine(), nextDouble() for reading user input

Loop Types & Control Statements

  • for loop – initialisation, condition, update; most common for counted iterations
  • while loop – condition checked before each iteration; runs zero or more times
  • do-while loop – condition checked after; always executes at least once
  • break – immediately exits the current loop
  • continue – skips the rest of the current iteration and moves to the next
  • Nested loops – outer loop controls rows, inner loop controls columns

Pattern Printing

  • Star (*) patterns – right triangle, left triangle, pyramid, diamond
  • Number patterns – sequential, mirrored, and Pascal’s triangle style
  • Analysing patterns – how to break any design into row count and column logic

1D Arrays

  • Array declaration: int[] arr = new int[5] – fixed size, zero-indexed
  • Initialisation at declaration: int[] arr = {10, 20, 30}
  • arr.length – getting the size of an array
  • Iterating with for loop and enhanced for-each loop
  • Common operations: finding max/min, sum, average, reverse, search
  • Arrays.sort() – sorting in ascending order

2D Arrays

  • Declaration: int[][] matrix = new int[rows][cols] – row-major storage
  • Nested loops to traverse rows and columns of a 2D array
  • Matrix operations – addition, transpose, diagonal sum

Defining & Using Methods

  • Method signature: access modifier, return type, method name, parameter list
  • Calling a method – passing arguments, receiving return values
  • void methods vs methods with a return type
  • static methods – called on the class directly without creating an object
  • Instance (non-static) methods – require an object to call
  • Method overloading – same name, different parameter types or count
  • Writing generic, reusable utility methods for common operations

Classes & Objects

  • Class as a blueprint – instance variables (fields) and instance methods
  • Creating objects: ClassName obj = new ClassName()
  • Default constructor – auto-provided by Java when no constructor is defined
  • Parameterised constructor – initialising objects with values at creation time
  • this keyword – resolving naming conflicts between parameters and instance fields

static & final Members

  • static variable – one copy shared across all instances of a class
  • static method – belongs to the class, not to any object
  • final variable – constant; must be assigned exactly once
  • final method – cannot be overridden by a subclass
  • final class – cannot be extended (e.g., String is a final class)

Inheritance

  • extends keyword – child class inherits all non-private members of the parent
  • super keyword – calling the parent class constructor or methods
  • Types: single inheritance, multilevel inheritance, hierarchical inheritance
  • Java does not support multiple class inheritance – why, and how interfaces solve this

Encapsulation & Access Modifiers

  • private, protected, public, package-private – scope of each
  • Encapsulation pattern – private fields with public getter and setter methods
  • Why encapsulation prevents invalid state and makes code easier to maintain
  • Method overloading – same method name, different parameter signature

Method Overriding & Runtime Polymorphism

  • Method overriding – child class provides its own implementation of a parent method
  • @Override annotation – compile-time check that overriding is valid
  • Runtime (dynamic) polymorphism – method resolved at runtime based on actual object type
  • Overloading vs overriding – compile-time vs runtime; key differences interviewers test

Object Type Casting

  • Upcasting – implicit; Animal a = new Dog() – always safe
  • Downcasting – explicit; Dog d = (Dog) a – requires instanceof check
  • instanceof operator – safely checking type before casting

Interfaces

  • interface keyword – defines a contract of method signatures without implementation
  • implements keyword – a class agrees to provide all interface methods
  • Interface methods are implicitly public abstract, fields are public static final
  • A class can implement multiple interfaces – Java’s answer to multiple inheritance

Abstract Classes

  • abstract class – cannot be instantiated; must be subclassed
  • abstract method – declared without a body; subclass must provide implementation
  • Can contain both abstract methods and fully implemented (concrete) methods
  • Interface vs abstract class – when to use each; key differences for interviews

String Class & Key Methods

  • String is immutable – every operation creates a new object in the String Pool
  • length(), charAt(int), indexOf(String), lastIndexOf()
  • substring(int start), substring(int start, int end)
  • toUpperCase(), toLowerCase(), trim()
  • replace(), contains(), startsWith(), endsWith()
  • equals() vs equalsIgnoreCase() vs == – why == compares references, not content
  • split(String regex), join(), toCharArray()

StringBuilder & StringBuffer

  • StringBuilder – mutable, not thread-safe, faster for single-threaded use
  • append(), insert(), delete(), reverse(), toString()
  • StringBuffer – mutable, thread-safe, used in multi-threaded programs
  • String vs StringBuilder vs StringBuffer – performance and thread-safety trade-offs

List – Ordered, Allows Duplicates

  • ArrayList – dynamic array; fast random access; allows duplicates; maintains insertion order
  • LinkedList – doubly-linked list; fast add/remove at ends; slower random access
  • Common methods: add(), get(int), remove(), size(), contains(), set()
  • Iterating with for-each and Iterator

Set – No Duplicates

  • HashSet – no duplicates, no guaranteed order; backed by a hash table
  • LinkedHashSet – no duplicates, preserves insertion order
  • TreeSet – no duplicates, elements stored in natural sorted order

Queue & Stack

  • Queue interface – FIFO; offer(), poll(), peek()
  • Stack – LIFO; push(), pop(), peek()
  • Vector – legacy thread-safe version of ArrayList

Map – Key-Value Pairs

  • HashMap – key-value pairs, no guaranteed order, allows one null key
  • LinkedHashMap – key-value pairs, preserves insertion order
  • Common methods: put(), get(), remove(), containsKey(), keySet(), values()

Sorting & Iteration

  • Comparable interface – compareTo() for natural ordering inside the class
  • Comparator interface – compare() for custom ordering defined outside the class
  • Collections.sort(list) and Collections.sort(list, comparator)
  • IteratorhasNext() and next() for safe manual traversal

Exception Handling Mechanism

  • What is an exception – an unexpected event that disrupts normal program execution
  • Checked vs unchecked exceptions – compile-time vs runtime
  • try block – code that may throw an exception
  • catch (ExceptionType e) – handling a specific exception type
  • Multiple catch blocks – handling different exception types separately
  • finally block – always executes; used for resource cleanup (closing files, connections)
  • throw keyword – manually throwing an exception from your code
  • throws keyword – declaring that a method may throw a checked exception
  • Common exceptions:
    • NullPointerException
    • ArrayIndexOutOfBoundsException
    • NumberFormatException
    • ArithmeticException

Selenium course

Tools & Setup

  • Installing Java JDK, Eclipse IDE, and configuring environment variables
  • Creating a Maven project and understanding pom.xml structure
  • Adding Selenium WebDriver dependency via Maven Central
  • Setting up ChromeDriver, GeckoDriver (Firefox), and EdgeDriver

WebDriver Fundamentals

  • Understanding the Selenium architecture – how WebDriver communicates with browsers
  • Instantiating WebDriver for Chrome, Firefox, and Edge browsers
  • Writing and running your first automation script end-to-end
  • Understanding the difference between Selenium 3 and Selenium 4

WebDriver Browser Commands

  • driver.get() and driver.navigate().to() – loading URLs
  • navigate().back(), navigate().forward(), navigate().refresh()
  • driver.manage().window().maximize(), setSize(), setPosition()
  • driver.getTitle() and driver.getCurrentUrl() for page verification
  • driver.quit() vs driver.close() – when to use each

💡 Locators are how your script finds elements on a page. Mastering all 8 strategies means you can automate any website, no matter how it is built.


All 8 Locator Types

  • By.id – fastest and most reliable when available
  • By.name – using the HTML name attribute
  • By.className – single CSS class targeting
  • By.tagName – selecting by HTML element type
  • By.linkText – exact anchor text matching
  • By.partialLinkText – partial anchor text matching
  • By.cssSelector – powerful CSS-based targeting
  • By.xpath – most flexible, works anywhere in the DOM

💡 CSS Selectors and XPath are the two most powerful locator types. Knowing both in depth allows you to find any element — even in the most complex web pages.


CSS Selector Techniques

  • Tag, ID, class, and attribute-based CSS selectors
  • Combining multiple attributes: input[type='text'][name='email']
  • Child and descendant selectors, sibling selectors
  • :nth-child(), ^=, $=, *= – starts-with, ends-with, contains patterns

XPath Techniques

  • Absolute XPath vs Relative XPath – differences and when to use each
  • XPath with attributes: //tag[@attribute='value']
  • contains(), starts-with(), text() functions
  • XPath axes: parent, child, following-sibling, preceding-sibling, ancestor
  • Grouping and index-based XPath: (//tag)[2]
  • AND / OR logical operators in XPath expressions

💡 Once you find an element, you need to interact with it – type, click, read values. These are the core actions every automation script performs.


WebElement Action Methods

  • sendKeys() – typing into text fields and input boxes
  • click() – clicking buttons, links, checkboxes, and radio buttons
  • clear() – clearing existing text from input fields
  • submit() – submitting forms directly

WebElement Property Methods

  • isSelected() – checking state of checkboxes and radio buttons
  • isEnabled() – verifying if a field or button is active
  • isDisplayed() – checking if an element is visible on screen
  • getText() – reading the visible text of any element
  • getAttribute() – reading any HTML attribute value
  • getCssValue() – reading applied CSS property values

💡 Many modern websites require mouse gestures and keyboard combos that a simple click cannot handle. The Actions class and screenshot tools cover exactly these scenarios.


Actions Class – Advanced Mouse & Keyboard

  • moveToElement() – hovering over menus and tooltips
  • doubleClick() and contextClick() (right-click)
  • dragAndDrop() and dragAndDropBy()
  • Keyboard actions: keyDown(Keys.SHIFT), keyUp(), sendKeys(Keys.ENTER)
  • Scroll actions using scrollToElement() and scrollByAmount() (Selenium 4)
  • build().perform() – chaining and executing action sequences

Capturing Screenshots

  • TakesScreenshot interface – full-page screenshot on test failure
  • Element-level screenshot using WebElement.getScreenshotAs()
  • AShot library – for full-page scrolling screenshots
  • JavaScript Executor-based screenshot approach

💡 Real applications open pop-ups, new tabs, and embed content in frames. Knowing how to switch between them keeps your scripts from getting stuck.


Window & Tab Handling

  • driver.getWindowHandle() – capturing the current window reference
  • driver.getWindowHandles() – getting all open window/tab references
  • driver.switchTo().window(handle) – switching between windows and tabs
  • Opening a new tab using Selenium 4’s newWindow(WindowType.TAB)
  • Closing child windows and returning to the parent window

Frame & Alert Handling

  • driver.switchTo().frame() – switching by index, name, or WebElement
  • driver.switchTo().defaultContent() – returning to the main page
  • driver.switchTo().alert() – handling JavaScript alerts and confirms
  • alert.accept(), alert.dismiss(), and alert.sendKeys()

Classes & Objects

  • Class as a blueprint – instance variables (fields) and instance methods
  • Creating objects: ClassName obj = new ClassName()
  • Default constructor – auto-provided by Java when no constructor is defined
  • Parameterised constructor – initialising objects with values at creation time
  • this keyword – resolving naming conflicts between parameters and instance fields

static & final Members

  • static variable – one copy shared across all instances of a class
  • static method – belongs to the class, not to any object
  • final variable – constant; must be assigned exactly once
  • final method – cannot be overridden by a subclass
  • final class – cannot be extended (e.g., String is a final class)

💡 Timing issues cause most automation failures. Proper synchronization makes your scripts reliable — even on slow networks or dynamic pages that load asynchronously.


Wait Types

  • Thread.sleep() – static wait (why it should be avoided in real scripts)
  • driver.manage().timeouts().implicitlyWait() – global element search timeout
  • WebDriverWait with ExpectedConditions – explicit conditional waits
  • Key conditions:
    • visibilityOfElementLocated
    • elementToBeClickable
    • textToBePresentInElement
    • alertIsPresent
  • FluentWait – polling interval, custom timeout, ignoring exceptions
  • Choosing the right wait strategy for different application behaviours

💡 POM is the industry-standard way to organise automation code. It separates locators from test logic — making scripts easier to maintain when the UI changes.


POM Architecture

  • Why POM exists – separation of page logic from test logic
  • Creating Page classes with locators and action methods
  • @FindBy annotation – declaring locators declaratively
  • PageFactory.initElements(driver, this) – initialising page elements
  • Structuring a multi-page project: LoginPage, HomePage, CartPage, etc.

Common Issues & Fixes

  • Understanding and handling StaleElementReferenceException
  • Lazy initialisation vs eager initialisation of page elements
  • Reusing page objects across multiple test classes

💡 TestNG is the test management backbone of most Selenium projects. It controls the order, grouping, and reporting of your tests — making your suite production-quality.


TestNG Annotations & Configuration

  • Core annotations: @Test, @BeforeMethod, @AfterMethod, @BeforeClass, @AfterClass, @BeforeSuite, @AfterSuite
  • Test grouping with groups attribute – running smoke vs regression sets
  • Parameterisation using @Parameters and testng.xml configuration
  • Data-driven testing using @DataProvider
  • Parallel test execution – configuring thread count in testng.xml
  • Test priority, dependency (dependsOnMethods), and enabled flag
  • Custom logging using Reporter.log() inside test methods

Assertions

  • Hard assertions with Assert – test stops immediately on failure
  • Soft assertions with SoftAssert – collect all failures, report at end
  • Common assertion methods: assertEquals, assertTrue, assertFalse, assertNull, assertNotNull
  • Choosing between hard and soft assertions based on test scenario

💡 Data-driven testing lets one script run across hundreds of input combinations stored in an Excel sheet — a standard practice in enterprise QA teams.


Apache POI – Excel Integration

  • Adding Apache POI dependency to pom.xml for .xlsx support
  • XSSFWorkbook, XSSFSheet, XSSFRow, XSSFCell – reading the Excel object hierarchy
  • Reading test data row-by-row from an Excel file into test scripts
  • Handling different cell types: String, Numeric, Boolean, Formula
  • Writing test results (Pass/Fail) back into the Excel sheet
  • Building a reusable ExcelUtils utility class for the framework

 

💡 This module brings everything together into a production-level framework — the kind you will actually work with inside a software company.


Framework Design (AFW)

  • Recommended folder structure: src/main for utilities, src/test for test scripts
  • Building a BaseTest class – centralised driver initialisation and teardown
  • Integrating POM page classes, Excel utilities, and TestNG configuration
  • Maven Surefire Plugin – triggering test suites from command line
  • Version control with GitHub – pushing the project, branching basics

Selenium Grid & Cross-Browser Testing

  • Selenium Grid architecture – Hub and Node setup for distributed execution
  • RemoteWebDriver – running tests on remote machines and browsers
  • Cloud-based grid execution using SauceLabs
  • Configuring browser capabilities for parallel cross-browser runs

Jenkins CI/CD Integration

  • Installing and configuring Jenkins for a Java/Maven project
  • Creating a Jenkins job linked to a GitHub repository
  • Scheduling automated test runs using cron-style build triggers
  • Viewing TestNG reports and build history inside Jenkins dashboard

Live Projects You Will Build

Flight Booking API

Microservices based airline reservation backend.

E-Commerce Platform

Full-featured Amazon clone with Cart & Payment Gateway.

Smart Banking System

Secure transaction portal with Spring Security & JWT.

Hospital Management

Patient records & doctor booking system.

Why Choose This Course?

Work on Live Industry Projects

Work on real-time projects used in companies

Start Freelancing with Real Clients

Start earning through freelancing platforms

Build Job-Ready Portfolio

Create portfolio to showcase your skills

100% Placement Assistance

Resume + mock interviews + job referrals

FAQs

What is Selenium Automation Testing?

Selenium is a popular automation testing tool used to automate web application testing.

You will learn Selenium WebDriver, Java, TestNG, frameworks, and automation projects.

Yes, Selenium Automation Testing is highly in demand for QA and automation roles.

Basic programming knowledge is helpful, but training starts from fundamentals.

Yes, the course includes real-time automation testing projects.