If there's a SelectExpression in the value, the Serializer should default to multiline formatting

NEW
Unassigned

Status

L20n
Python Library
5 months ago
4 months ago

People

(Reporter: stas, Unassigned)

Tracking

Details

(Reporter)

Description

5 months ago
In the following test, the value is a Pattern with no new lines, so the serializer doesn't know that it should use multiline formatting.

Let's detect SelectExpressions in Patterns and default to multiline formatting for clarity. This will result in an opposite problem which I think is okay. I don't know however how to fix it in the future.

    @unittest.skip("The serializer doesn't know it's multiline.")
    def test_select_expression_in_simple_multiline(self):
        input = """\
            foo =
                Foo { sel ->
                   *[a] A
                    [b] B
                }
        """
        self.assertEqual(pretty_ftl(input), dedent_ftl(input))
(Reporter)

Updated

4 months ago
No longer blocks: 1396580
You need to log in before you can comment on or make changes to this bug.