basic-navigation Scenario 8 — Count Review Cards
Written by RTILA X Engineering Team
What You'll Learn
Count repeated elements on a page
Real-World Use Case
Validating the number of reviews displayed
Review List
Twelve review cards, each with a name and star rating.
Alex M.
★★★★★Outstanding sound quality
Jordan P.
★★★★☆Comfortable for long flights
Casey W.
★★★★☆Great wireless experience
Drew K.
★★★★★Perfect upgrade
Sam B.
★★★★★Crisp 4K
Leslie G.
★★★★☆Great value
Morgan T.
★★★★★Beautiful display
Riley N.
★★★★☆Highly recommended
Quinn F.
★★★★★Keyboard heaven
Hollis D.
★★★★☆Solid build
Avery S.
★★★★★Typing feels great
Emery L.
★★★☆☆Good but not perfect
Review Card Count
12
RTILA X Automation Project
{
"name": "Count_Review_Cards",
"settings": {
"urls": [
"https://learn.rtila.com/scenarios/basic-navigation/8"
],
"headless": false,
"navigation_timeout": 30000,
"max_concurrent_workers": 1,
"humanoidEnabled": true,
"humanoidSensitivity": "medium"
},
"datasets": {
"review_count": {
"item_selector": "css=html",
"properties": [
{
"name": "count",
"type": "count",
"selector": "css=.review-card"
}
]
}
},
"commands": [
{
"command": "goto",
"params": {
"url": "https://learn.rtila.com/scenarios/basic-navigation/8"
}
},
{
"command": "wait_for_selector",
"params": {
"selector": "css=.review-card"
}
},
{
"command": "extract_data",
"params": {
"dataset": "review_count"
}
}
]
}
RTILA X Concepts
The count property type returns the number of matching elements rather
than their content. The parent selector here is css=html so the entire
page is considered one context.
Did you complete this scenario?
Ready to run this automation?
Copy the project JSON above, open RTILA X, create a new project, and paste it.
This scenario covers 1 RTILA X command and is referenced in 2 learning articles.
Continue Learning
Was this helpful?
Thank you for your feedback!