Parse Rule XML does not find incorrect XML

I used Parse Rule XML from Create a new LanguageTool rule on this syntactically incorrect rule:

        <rule id="RULE_EDITOR_TEST" name="Rule Editor Test">
            <pattern>
                <token regexp="yes">bucket|flower pot|spade|</token>
            </pattern>
            <message>Did you mean <suggestion>equipment</suggestion>?</message>
            <example correction="Michael">Put the <marker>bucket</marker> in the shed.</example>
            <example>This <marker>equipment</marker> is dirty.</example>
        </rule>

The Rule Editor did not give a warning about the incorrect syntax.

Just parsing won’t run the full checks, to do that you need to switch to expert mode and click “Check XML”.

Expert mode does not give a warning for this incorrect token:
<token regexp="yes">bucket|flower pot|spade|</token>

I’ve added a test for that, tests will fail if there’s a whitespace.

Sorry, had to take it out again, that that didn’t work properly yet.