
- Selenium - Home
- Selenium - Overview
- Selenium - Components
- Selenium - Automation Testing
- Selenium - Environment Setup
- Selenium - Remote Control
- Selenium - IDE Introduction
- Selenium - Features
- Selenium - Limitations
- Selenium - Installation
- Selenium - Creating Tests
- Selenium - Creating Script
- Selenium - Control Flow
- Selenium - Store Variables
- Selenium - Alerts & Popups
- Selenium - Selenese Commands
- Selenium - Actions Commands
- Selenium - Accessors Commands
- Selenium - Assertions Commands
- Selenium - Assert/Verify Methods
- Selenium - Locating Strategies
- Selenium - Script Debugging
- Selenium - Verification Points
- Selenium - Pattern Matching
- Selenium - JSON Data File
- Selenium - Browser Execution
- Selenium - User Extensions
- Selenium - Code Export
- Selenium - Emitting Code
- Selenium - JavaScript Functions
- Selenium - Plugins
- Selenium WebDriver Tutorial
- Selenium - Introduction
- Selenium WebDriver vs RC
- Selenium - Installation
- Selenium - First Test Script
- Selenium - Driver Sessions
- Selenium - Browser Options
- Selenium - Chrome Options
- Selenium - Edge Options
- Selenium - Firefox Options
- Selenium - Safari Options
- Selenium - Double Click
- Selenium - Right Click
- HTML Report in Python
- Handling Edit Boxes
- Selenium - Single Elements
- Selenium - Multiple Elements
- Selenium Web Elements
- Selenium - File Upload
- Selenium - Locator Strategies
- Selenium - Relative Locators
- Selenium - Finders
- Selenium - Find All Links
- Selenium - User Interactions
- Selenium - WebElement Commands
- Selenium - Browser Interactions
- Selenium - Browser Commands
- Selenium - Browser Navigation
- Selenium - Alerts & Popups
- Selenium - Handling Forms
- Selenium - Windows and Tabs
- Selenium - Handling Links
- Selenium - Input Boxes
- Selenium - Radio Button
- Selenium - Checkboxes
- Selenium - Dropdown Box
- Selenium - Handling IFrames
- Selenium - Handling Cookies
- Selenium - Date Time Picker
- Selenium - Dynamic Web Tables
- Selenium - Actions Class
- Selenium - Action Class
- Selenium - Keyboard Events
- Selenium - Key Up/Down
- Selenium - Copy and Paste
- Selenium - Handle Special Keys
- Selenium - Mouse Events
- Selenium - Drag and Drop
- Selenium - Pen Events
- Selenium - Scroll Operations
- Selenium - Waiting Strategies
- Selenium - Explicit/Implicit Wait
- Selenium - Support Features
- Selenium - Multi Select
- Selenium - Wait Support
- Selenium - Select Support
- Selenium - Color Support
- Selenium - ThreadGuard
- Selenium - Errors & Logging
- Selenium - Exception Handling
- Selenium - Miscellaneous
- Selenium - Handling Ajax Calls
- Selenium - JSON Data File
- Selenium - CSV Data File
- Selenium - Excel Data File
- Selenium - Cross Browser Testing
- Selenium - Multi Browser Testing
- Selenium - Multi Windows Testing
- Selenium - JavaScript Executor
- Selenium - Headless Execution
- Selenium - Capture Screenshots
- Selenium - Capture Videos
- Selenium - Page Object Model
- Selenium - Page Factory
- Selenium - Record & Playback
- Selenium - Frameworks
- Selenium - Browsing Context
- Selenium - DevTools
- Selenium Grid Tutorial
- Selenium - Overview
- Selenium - Architecture
- Selenium - Components
- Selenium - Configuration
- Selenium - Create Test Script
- Selenium - Test Execution
- Selenium - Endpoints
- Selenium - Customizing a Node
- Selenium Reporting Tools
- Selenium - Reporting Tools
- Selenium - TestNG
- Selenium - JUnit
- Selenium - Allure
- Selenium & other Technologies
- Selenium - Java Tutorial
- Selenium - Python Tutorial
- Selenium - C# Tutorial
- Selenium - Javascript Tutorial
- Selenium - Kotlin Tutorial
- Selenium - Ruby Tutorial
- Selenium - Maven & Jenkins
- Selenium - Database Testing
- Selenium - LogExpert Logging
- Selenium - Log4j Logging
- Selenium - Robot Framework
- Selenium - AutoIT
- Selenium - Flash Testing
- Selenium - Apache Ant
- Selenium - Github Tutorial
- Selenium - SoapUI
- Selenium - Cucumber
- Selenium - IntelliJ
- Selenium - XPath
- Selenium Miscellaneous Concepts
- Selenium - IE Driver
- Selenium - Automation Frameworks
- Selenium - Keyword Driven Framework
- Selenium - Data Driven Framework
- Selenium - Hybrid Driven Framework
- Selenium - SSL Certificate Error
- Selenium - Alternatives
Selenium IDE - Assert/Verify Methods
Selenium IDE uses assert and verify methods to check if a certain text, element, page title, and so on matches with the requirements. These two methods basically help us to conclude if a test has passed or failed based on the verification points added (in the form of assert and verify commands).
What is an Assert Command?
In Selenium IDE, an assert command is used to verify if a certain situation is matching with the specification document. In case, they are not matching, the test execution stops at the point of a mismatch.
Example with Assert Command
Let us take an example of the below page, where we would capture the page title Selenium Practice Radio Button and check if the correct page title is displayed using the assert command.

The steps to use an assert command are listed below −
Step 1 − Follow the Steps 1 to 4 as described in the link Selenium IDE Store Variables.
Step 2 − Enter open in the Command field, and Selenium Automation Practice Form in the Target field, to launch the application.
Step 3 − Enter store title in the Command field, and pageTitle in the Value field. Please note, pageTitle is variable to capture the title of the application launched.
Step 4 − Enter assert title in the Command field, ABC in the Target field. Please note, in this step we are verifying if the page tile is ABC.
Step 5 − Enter echo in the Command field, ${pageTitle} in the Target field. Please note, this would print the text we obtained in Step6 under the Log in Selenium IDE.
Step 6 − Enter close in the Command field to close the browser window.
Step 7 − Click on the three dots appearing at the left pane, then select the Rename option.
Step 8 − Enter a name, say Test6 under the Rename Test case field, then click on Rename. The entered name would appear on the left of Selenium IDE.
Step 9 − Click on the Run all tests from the top, and wait for the test execution to complete. In our example, we would see Runs: 1, Failures: 1, and a red bar denoting the test ran unsuccessfully with failures. Also, the message Test6 ended with 1 error(s) would appear under the Log.

In the example above, we had obtained the page title which is Selenium Practice Radio Button. However, we had added the assert title command to check if the page title is equal to ABC. Hence the actual and the expected values did not match. Moreover, due to the assert command, the execution halted and the steps 4, and 5 did not execute.
What is a Verify Command?
In Selenium IDE, a verify command is also used to verify if a certain situation is matching with the specification document. In case, they are not matching, the test execution does not stop at the point of a mismatch. The error is captured at the Log in Selenium IDE and the steps after the error IS encountered also get executed.
Example with Verify Command
Let us take the same above example, where we would capture the page title Selenium Practice Radio Button and check if the correct page title is displayed using the verify command.
The steps to capture the browser title are listed below −
Step 1 − Follow the Steps 1 to 4 as described in the link Selenium IDE Store Variables.
Step 2 − Follow steps 2 and 3 from the previous example.
Step 3 − Enter verify title in the Command field, ABC in the Target field. Please note, in this step we are verifying if the page tile is ABC.
Step 4 − Follow steps 8,9, 10, 11, and 12 from the previous example.

In the example above, we had obtained the page title which is Selenium Practice Radio Button. However, we had added the verify title command to check if the page title is equal to ABC. Hence the actual and the expected values did not match. Moreover, even after encountering failure in step3 the steps 4, and 5 executed and the execution did not stop in between, simultaneously, the error also got recorded under the Log.
Difference between Assert and Verify Commands
From the above examples, we can infer that both assert and verify commands can be used for verification purposes. But in case of errors encountered in a test, the execution stops at the failed step, and remaining steps do not get executed while assert command is used. However, the execution continued even after encountering a failed step, while we are using the verify command. The error encountered is also recorded under the Log in Selenium IDE for both the commands.
Conclusion
This concludes our comprehensive take on the tutorial on Selenium IDE Assert/Verify methods. Weve started with describing what is an assert and a verify command in Selenium IDE, and walked through examples having an assert command and a verify command, illustrated how to use them, and the basic differences between the two commands along with Selenium. This equips you with in-depth knowledge of the assert and verify methods in Selenium IDE. It is wise to keep practicing what youve learned and exploring others relevant to Selenium to deepen your understanding and expand your horizons.