Overview
The Verify Text node provides specialized text verification capabilities for web pages. It’s a variant of the Verify Element node focused specifically on text content validation with advanced pattern matching options.This node is a specialized configuration of the Verify node with
verificationType: 'elementText'. For comprehensive verification options, see Verify Element.Configuration
Set to
browser for text verification.Set to
elementText for text verification.Element selector containing the text to verify.
Type of selector:
css, xpath, text, getByRole, etc.Expected text content or pattern.
How to match the text:
equals- Exact match (case-sensitive)contains- Text contains the expected valuestartsWith- Text starts with the expected valueendsWith- Text ends with the expected valueregex- Regular expression match
If
true, failed verifications log warnings but don’t stop execution.Match Types Explained
equals
Exact string match (case-sensitive).contains
Text contains the expected substring.startsWith
Text begins with the expected prefix.endsWith
Text ends with the expected suffix.regex
Regular expression pattern matching.Examples
Basic Text Verification
Pattern Matching
Error Messages
Success Messages
With Retry
Wait for Dynamic Text
Optional Verification
Fail Silently
Regex Pattern Examples
| Pattern | Description | Matches |
|---|---|---|
^\d{3}-\d{4}$ | Phone format | 555-1234 |
^[A-Z]{2}\d{4}$ | License plate | AB1234 |
^\$\d+\.\d{2}$ | Price | $19.99 |
^\d+%$ | Percentage | 75% |
^v\d+\.\d+\.\d+$ | Version | v1.2.3 |
\b\d{1,3}(,\d{3})*\b | Formatted number | 1,234,567 |
Common Use Cases
Form Validation
Status Monitoring
Content Validation
Notes
Text matching is case-sensitive for all match types. Use regex with case-insensitive flags if needed:
(?i)patternThe
contains match type is useful for verifying dynamic content where exact text may vary but key terms remain constant.Related Nodes
- Verify Element - Element state verification
- Get Text - Extract text content
- Wait - Wait for conditions
- JavaScript Code - Custom text processing
