Skip to content

Pre-formatted blocks in documentation get modified by formatter #1773

Description

@UniqueActive

Hi!

I saw that Robot Framework supports pre-formatted blocks of text in documentation with this syntax:

*** Settings ***
Documentation    Here is some regular text that should be formatted
...
...              | This pre-formatted text should stay intact
...              |    1.2 <----> 1.2    .--> 1.2
...              |    1.3 <-.    1.3 <-´ ,-> 1.3
...              |    1.4    `-> 1.4    /    1.4
...              |    1.5        1.5 <-´     1.5

However when running the robocop formatter (default settings), the pre-formatted text is modified (last line), I assume because of the >4 spaces:

*** Settings ***
Documentation       Here is some regular text that should be formatted
...
...                 | This pre-formatted text should stay intact
...                 |    1.2 <----> 1.2    .--> 1.2
...                 |    1.3 <-.    1.3 <-´ ,-> 1.3
...                 |    1.4    `-> 1.4    /    1.4
...                 |    1.5    1.5 <-´    1.5

Currently we have to work around this by using # robocop fmt: off for the Documentation.

Thanks in advance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions