Custom Templates for BDD Feature Files

Custom Templates for BDD Feature Files

When opening a new Behavior-Driven Development (BDD) test case in the Squish IDE, a default feature file will display. Since Squish 6.4.1, you can define your own feature file template to open when creating a new test case. 

Customizing Your Feature File

Within the scriptmodules/ directory (located in Squish’s application directory), you’ll find a test_template.feature file. To create the custom template, first open the file in a text editor of your choice. It appears as follows:

Default BDD Feature File Template

You can then edit the file to adapt it to the needs of your organization. After saving the changes, every newly created BDD test case will open following your template. Here is a sample, custom BDD feature file template:

Example froglogic custom feature file.

Template entries will vary from team to team, but some common entries for custom templates include:

  • Original author
  • Creation date
  • Requirement associated with the test case
  • Workflow or project the test case belongs to
  • A mini-template for user stories
  • Internal and external documentation
  • Copyright statement and licensing
  • Additional information (e.g., a boilerplate footer)

BDD Tutorials

Check out some of our BDD tutorials on our YouTube channel for some helpful tips and tricks:

Christian Franke started as a support engineer in 2017 right after finishing his Bachelor's degree. Since then, he's taken over sales-relevant tasks as well as conducting trainings and offering consulting from time to time.


Leave a reply

电子邮件地址不会被公开。 必填项已用*标注