Unique Within Their Feature File

« Table of Contents »
Previous « Indicate Primary or Secondary Behaviour

The Behaviour Specification Handbook

Effective Behaviour Specification Descriptions

Unique Within Their Feature File

Helpful, intention-revealing Behaviour Specification Descriptions can become a little verbose. As such, it can be very useful for team members to have a mechanism to easily identify or refer to a specific Behaviour Specification from the long list of specifications in the same feature file.

In my experience, it is beneficial for each Behaviour Specification Description to have a numeric-based identifier that is unique within the scope of the feature file. This helps team members to quickly find or reference specific specifications in that feature file.

It also is better if the numeric-based identifier is not a consecutive, sequential number. By intentionally leaving gaps between the numbers, new Behaviour Specifications easily can be inserted in between the existing behaviours, without causing people to have the desire to do any time-wasting renumbering.

In addition it is benficial to prefix the numeric-based identifer with an acronym that represents the type of test - such as UT for a Unit Test or IT for an Integration Test. This is in addition to the @tag above the scenario description.

It also can be helpful and meaningful to logically group a specific positive behaviour with its related negative behaviours. All the related behaviours can be given the same numeric identifer, and then be suffixed with a different letter of the alphabet to make them each unique. See further below for an example.


Next » Unique Without Their Feature File