Appearance
Writing Effective Test Scenarios
This section covers the best practices for using BVT. Especially the guidelines on how to best create test scenarios that BVT can process easily and accurately.
Overview
- Create clear feature files: The AI engine is not familiar with your application. Think of it as a fresh recruit. Ensure that your steps are clear enough that if handed to a new employee, they could carry them out without confusion.
- Enhance accessibility of the website/application under test: Enhancing the accessibility of your website/application under test will optimize the engine's performance.
- UX matters: It might seem apparent, but the AI engine will perform optimally on well-designed apps with a good user experience.
- Consistency is Key: When providing instructions, maintain consistency with the terminology of your application. For instance, if an entity in your app is labeled "users," avoid referencing them as "customers" or "subscribers."
Constraints
The cucumber tests managed by our AI agent come with specific constraints:
* For Given/When commands, actions such as click/fill are permissible.
* For Then commands, only verification commands should be used.
Enhance the Engine's Understanding: Two Additional Techniques
Utilize Comments
You can place comments above the scenario step or at the beginning of the scenario itself.
In the example below, we guide the AI engine in creating a private GitHub repository.
Note
A comment placed above the scenario applies to all subsequent steps.
gherkin
Scenario Outline: Create a new repository
# Ensure the repository is private
Given I create a new repository named "<repo>" with description "<description>" and a README file
Examples:
| repo | description |
| {{string.alpha(10)}} | Sample description|