Skip to content

JUnit Report Formatting breaks with LabVIEW Error Cluster as property #209

@Kruemmelkeks

Description

@Kruemmelkeks

I noticed, that when I use the "Error Cluster from Error Code.vi" this will cause the XML format to break due to the <ERR> tag inside the Error source.

This is a sample code:

Image

As you can see, the error source string will have the <ERR> . When trying to create a JUnit-Report, I get this:

    <testcase classname="JUnit Report Test Gitlab" name="Fail-Test">
        <failure message="{Cluster element index: 1 -- Expected value: 42, Asserted value: 5999}">"FAIL"</failure>
        <properties>
            <Real Error>
                <status>true</status>
                <code>42</code>
                <source>Repport Test.vi<ERR>
Dummy-Test</source>
            </Real Error>
        </properties>
    </testcase>

XML parsers will consider the <ERR> as an opened XML-Tag without a closing statement. The problem seems to lie within the Serialization class which parses all properties from variant attributes. It looks like it does not escape the tag correctly. But I did not have time do dig deeper into it yet.

Metadata

Metadata

Assignees

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