Skip to content

πŸ”§ JUnitParser.validate() has no caller, and every fixture is invalid against the shipped JUnit.xsdΒ #2015

Description

@chrisjsewell

JUnitParser.validate() (ub_test_reports/junitparser.py:146, 39b73156) parses the shipped schemas/JUnit.xsd and validates the report against it β€” and nothing calls it: not the directives, not the converter, not the plugin. Found by #2009's mutation M6b: a wheel with the XSD deleted stayed green until two tests were added for the method itself. Those tests also measured that every XML fixture in the suite is invalid against the strict Ant schema (skips not allowed, timestamp/hostname required, properties expected) β€” pytest's, googletest's, ctest's output included β€” so wiring validate() into the parsing path would reject real reports.

Decide: either (a) delete validate() and the XSD (and the two tests, the junit_xsd constructor argument, the artefact fence's "must ship the XSD" line), or (b) keep it as an opt-in diagnostic with a lenient schema that matches what the parsers actually accept β€” in which case the schema is the contract and needs the fixtures as its corpus. (a) is smaller and honest about what ships today. Marco's call, since the XSD predates the monorepo; whichever it is, the changelog of the core's next release says so.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementpkg: ub-test-reportsConcerns the ub-test-reports package (packages/ub-test-reports): the Sphinx-free test-reports core

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions