Certification: AI-driven Test Automation
Your Progress: out of 26
testRigor has a built-in rule login, which uses credentials stored in the Settings
You can also create reusable rules. There are two types: for filling forms, and rules containing execution steps. It makes sense to create a reusable rule for frequently performed actions that are the same in multiple test cases.
login click "Men Clothing" scroll down click "Men's cargo shorts" click "brown" click "Size 34" click "Add to cart" check that page contains "Your order is nearly complete!"
go to checkout page check page contains "Add to cart"
- Save, then Find and Update Name
- Save, then Find and Replace Steps – will scan for “go to checkout page” throughout your test suite and replace steps with the ones you just created in the rule.
You can also parameterize rules, as well as use rules inside rules.
Auto-apply rules in pre-condition
When creating a reusable rule, there’s a section below the steps called “Fields related to auto-apply rules and auto-discovery.” Open this section and enable “Auto apply on every step of every test case” These rules are never written in test cases. They are added automatically when the preconditions are met. This is to deal with unpredictable situations like ads and popups that appear at random times.
Empty rules for BDD
Just add the rule names in the test case and you will be prompted with creation of an empty rule.
Note: It’s recommended to use standardized language so that everyone on the organization’s team understands it and there is no confusion.
Using test cases as reusable rules for dependencies
You can create a test, put some steps into a rule and use that rule inside a different test case.