Allure Behave configuration

Allure Behave accepts some options via the behave's “user-defined data”. All the options should be prefixed with AllureFormatter..

  • To pass configuration options to the behave command-line utility, use the -D (or --define) flag. For example:

    Text
    python -m behave -D AllureFormatter.hide_excluded=true
  • To save the configuration options permanently, add them to the behave.userdata section of the behave configuration file. For example:

    INI
    [behave] format = allure_behave.formatter:AllureFormatter outfiles = allure-results [behave.userdata] AllureFormatter.link_pattern = {} AllureFormatter.issue_pattern = https://github.com/allure-framework/allure-python/issues/{} AllureFormatter.hide_excluded = true

Define a link pattern — a template that can be used to construct full URLs from short identifiers, see reference. The pattern must contain {} at the position where the identifier should be placed.

The pattern will be applied to all links of type “link”, i.e. all links that are defined using the @allure.link tag or the link() function without providing a non-default link_type.

issue_pattern

Define an issue pattern — a template that can be used to construct full URLs from short identifiers, see reference. The pattern must contain {} at the position where the identifier should be placed.

The pattern will be applied to all links of type “issue”, i.e. all links that are defined using the @allure.issue tag, the issue() function or the link() function with link_type="issue".

hide_excluded

This option affects how Allure behave treats scenarios that are skipped by behave, e.g., based on a tag expression.

By default, the test report will include such scenarios, with their test results marked as Skipped (see Status). However, if this configuration option is set to true, the skipped scenarios will be excluded from the test report entirely.

Powered by
logo

Join our newsletter

Join our community

We aim to make Allure Report as reliable and user-friendly as possible, and together with the community, we're here to help when problems arise.

© 2024 Qameta Software Inc. All rights reserved.