Skip to content

Utils

formatting...

Module contains steps that can be useful during development or troubleshooting of a feature file, but should not be included in a finished, testable, feature.

Add orphan template

Add arbitrary templats to fool grizzly that a variable is being used.

This step should be avoided at all costs, escpecially if you do not know what you are doing. There are cases that grizzly will complain that a variable is declared, but not found in any templates, with this step it is possible to "fool" that logic, by adding a template containing that variable.

When adding this step in a feature-file, you should also write an bug issue detailing why it was necessary to use it, so the root cause can be fixed.

Example

Then add orphan template "{{ hello world foobar }}"

Arguments

Name Type Description Default
template str

templating string with jinja2 template containing variable names

required

Fail scenario

Force a failed scenario. Can be useful when writing a new scenario. The scenario will fail before locust has started, so only when the scenario is setup.

Example

Then fail