You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
NOTE: Indentation of the opening """ is unimportant, although the common practice is to indent them. The indentation inside the triple quotes, however, is significant. Each line of the doc string will be dedented according to the opening """. Indentation beyond the column of the opening """ will therefore be preserved.
However, in testing, when writing steps with docstrings, lines inside the triple backticks (```) or triple quotes (""") are dedented according to the first line.
Examples
The following two steps result in identical docstrings:
And the output should contain:
"""
"id": 42,
"foo": "bar",
"""
And
And the output should contain:
"""
"id": 42,
"foo": "bar",
"""
However, the following results in the second line being indented by two spaces:
And the output should contain:
"""
"id": 42,
"foo": "bar",
"""
I can provide a minimum reproducible example (MRE) if requested.
The text was updated successfully, but these errors were encountered:
Summary
(Originally opened as cucumber-rs/cucumber#339.)
According to the documentation:
However, in testing, when writing steps with docstrings, lines inside the triple backticks (```) or triple quotes (""") are dedented according to the first line.
Examples
The following two steps result in identical docstrings:
And
However, the following results in the second line being indented by two spaces:
I can provide a minimum reproducible example (MRE) if requested.
The text was updated successfully, but these errors were encountered: