Skip to content

Migrating to v5 Tags

aryehcitron@gmail.com edited this page Oct 28, 2026 · 2 revisions

Labels and categories are tags

Kronikol 5.0.0 keeps one list of tags on each feature and on each scenario, where 4.x kept a feature's labels and a scenario's labels and categories. A scenario's tags in the report are its feature's tags, then its own. Every adapter reads its framework's own tagging (Tags and Attributes › Tags lists where each one looks), so a suite whose 4.x report showed no tags can show them on 5.0.0 without a change to its tests.

What changed

4.x 5.0.0
The model Feature.Labels; Scenario.Labels and Scenario.Categories Feature.Tags and Scenario.Tags, each the tags written at that level
Where tags come from LightBDD's [Label] and [ScenarioCategory], Gherkin tags, BDDfy's tags and the tests NDJSON; the xUnit, NUnit, MSTest and TUnit adapters read none every adapter: xUnit Category traits, NUnit [Category], MSTest [TestCategory], TUnit [Category], BDDfy's tags and its test's Category traits, LightBDD's [Label] and [ScenarioCategory], Gherkin tags (a Rule:'s included) and the tests NDJSON
@category:smoke, .WithTags("category:smoke") the category smoke (on BDDfy, the label category:smoke) the tag smoke: the prefix is read and dropped, with no warning
Case Smoke and smoke were two categories with a button each, and @smoke matched both one tag, spelled as the report first meets it; only ASCII letters fold, so Über and über are two
LightBDD's [HappyPath] the label Happy Path as well as the flag the flag only: Happy Path is a happy-path name on every lane
The filter box a Categories row: All, a button per category, Uncategorized and an OR/AND switch one Tags row: a chip per tag with its count, Happy Path first, Untagged, and an ANY/ALL switch
A feature's tags a badge and free-text search only they count for each of the feature's scenarios, in the Tags row and in @tag search
@tag search a scenario's own labels and categories the Tags row's tags, Happy Path included; @"two words" for a tag with a space
Scenario element attributes data-labels and data-categories data-tags, each tag percent-encoded, joined with commas
Toggle default ReportToggleDefaults.CategoryFilterMode ReportToggleDefaults.TagFilterMode (default Or, which the switch shows as ANY)
Retries on the ingest lanes a retry N label for each earlier attempt one retry badge drawn from the attempt (retry 2 for a third attempt); an author's own retry 2 is an ordinary tag
Data files labels and categories (Labels and Categories in YAML and XML) tags (Tags, and <Tags><Tag> in XML), each level's own; Specifications.md prints one Tags: line
CTRF tags held the scenario's labels; its categories were in extra.categories tags hold the scenario's tags, its feature's first; no extra.categories
kronikol query scenarios --label; --json items carry labels and categories --tag, with --label still taken as the same flag; --json items carry tags, the feature's first
kronikol merge a merged feature kept the first shard's labels a merged feature keeps the tags every shard gives it, and a shard's other feature tags move onto that shard's scenarios

Only the framework's category attribute is read: other xUnit trait keys, such as [Trait("Produces", "openapi.json")], and NUnit or TUnit properties are not tags.

Code

These members are gone, so code that uses them does not build on 5.0.0:

  • Feature.Labels: use Feature.Tags.
  • Scenario.Labels and Scenario.Categories: use Scenario.Tags, which holds both. Code that built a scenario with labels and categories puts both lists in Tags.
  • ScenarioTags.Classified.Labels and .Categories: Classified is (Tags, Endpoint, IsHappyPath).
  • ReqNRollConstants.CategoryTagPrefix: a category: prefix is read and dropped wherever a tag is read, and ScenarioTags.CategoryPrefix names it.
  • ReportToggleDefaults.CategoryFilterMode: set TagFilterMode.
  • ReportGenerator.GenerateYamlSpecs: a second writer of the specifications YAML that nothing in Kronikol called. The run writes Specifications.yml as before.

HappyPathDetection.IsHappyPathTag also takes Happy Path, with its space.

Data files and tools

  • Kronikol.Tool 5.x reads a 4.x file (kronikol query, kronikol ctrf, kronikol card from 5.21.0, and kronikol merge): its labels and categories are its tags, and a feature's labels are the feature's. The retry N labels a 4.x ingest generated are left out where the scenario's attempt accounts for them. A report Kronikol4J wrote with labels and categories reads the same way.
  • A 4.x tool reads a 5.0.0 file as untagged. This change does not move formatVersion (it stays 3), so the file is not refused and its tags are skipped as a key the tool does not know: query scenarios --label matches nothing, kronikol ctrf writes no tags, and kronikol merge writes a merged report without them. Read 5.0.0 reports with Kronikol.Tool 5.x.
  • History does not read tags, so the history action and kronikol history work as before, whichever version of the tool reads the file.
  • A committed Specifications.yml, .json or .xml changes on the upgrade: its Labels and Categories become Tags (tags in JSON), and a suite that tags its tests through its framework gains tags it did not have.
  • Your own scripts that read labels or categories from TestRunReport.json read tags, on the feature and on the scenario. A scenario's tags in the report are its feature's, then its own.

The report

  • The Categories row is gone, and with it the classes a custom stylesheet may target: .category-filters, .category-toggle, .category-active and .cat-mode-toggle.
  • A link a 4.x report wrote keeps its meaning: cats= is read as tags=, catmode= as the tag mode when the link has no tagmode=, and __uncategorized__ as Untagged. 5.0.0 writes tags=, tagx= and tagmode=, each name percent-encoded (Generated Reports › Deep links).

What a report shows differently

Besides the tags the adapters now read, 5.0.0 changes what some reports show:

  • ReqNRoll: a feature's tags are its Feature:'s (Reqnroll's FeatureInfo.Tags). 4.x read them from the feature's first scenario, which gave that scenario's rule tags to the whole feature and lost a feature tag the scenario repeated.
  • Gherkin rules: a Rule:'s tags reach its scenarios, on ReqNRoll and on the Cucumber Messages lane, where 4.x dropped a plain rule tag.
  • NUnit [TestCase]: [HappyPath] on a [TestCase] method marks its cases, and a fixture whose first captured test is a [TestCase] keeps its [Endpoint].
  • A tag with a comma, a double quote or a space filters, is found by search and survives a link. 4.x split a tag at a comma, and a quote in one broke a shared link.
  • A parameterized group shows the tags all of its rows carry, less its feature's.
  • The chips' order no longer depends on the machine's culture: Happy Path first, then by name with ASCII letters folded.

Home · 🔍 Search this wiki Full-text search across every page. The “Pages” list above matches page and heading names, not page content.


Demo


Getting Started

Common Tasks

Integration Guides

Uninstrumentable / polyglot backends

Extensions

Configuration

Features

Reference

Clone this wiki locally