diff --git a/tests/feature/description.feature b/tests/feature/description.feature new file mode 100644 index 0000000..08c8bd5 --- /dev/null +++ b/tests/feature/description.feature @@ -0,0 +1,12 @@ +Feature: Description + + In order to achieve something + I want something + Because it will be cool + + + Some description goes here. + + Scenario: Description + + Given I have a bar diff --git a/tests/feature/test_description.py b/tests/feature/test_description.py new file mode 100644 index 0000000..a1577e6 --- /dev/null +++ b/tests/feature/test_description.py @@ -0,0 +1,21 @@ +"""Test descriptions.""" +from pytest_bdd import scenario + + +def test_description(request): + """Test description for the feature.""" + @scenario( + 'description.feature', + 'Description' + ) + def test(): + pass + + assert test.__scenario__.feature.description == """In order to achieve something +I want something +Because it will be cool + + +Some description goes here.""" + + test(request)