Class: SkillBench::Services::JUnitFormatter
- Inherits:
-
Object
- Object
- SkillBench::Services::JUnitFormatter
- Defined in:
- lib/skill_bench/services/junit_formatter.rb
Overview
Formats evaluation results as JUnit XML for CI consumption.
Two entry points share the same per-result verdict/score logic:
JUnitFormatter.format emits a single-result suite (one skill-bench run --all produces a single JUnit artifact.
Constant Summary collapse
- CLASSNAME =
classname attribute applied to every emitted
. 'SkillBench'
Class Method Summary collapse
-
.format(result) ⇒ String
Format a single result as a JUnit XML document.
-
.format_batch(aggregate) ⇒ String
Format an aggregate batch envelope as one JUnit XML document.
Class Method Details
.format(result) ⇒ String
Format a single result as a JUnit XML document.
Supports both legacy format (result) and modern DeltaReport format.
23 24 25 |
# File 'lib/skill_bench/services/junit_formatter.rb', line 23 def self.format(result) suite([result]) end |
.format_batch(aggregate) ⇒ String
Format an aggregate batch envelope as one JUnit XML document.
Emits a single
34 35 36 |
# File 'lib/skill_bench/services/junit_formatter.rb', line 34 def self.format_batch(aggregate) suite(aggregate[:results] || []) end |