Changelog:
New features:
- Negative matcher assertions. The kotest and hamkrest test-support cores gain
noneMatching(matcher)— aMatcher<Collection<T>>that passes when no element matches, failing with the offending elements listed.WithKotest/WithHamkrestgain directthenContinually(spec)overloads, so aThenSpeccan be asserted over a window (delegating to the existingPollingScopeform: the matcher must hold on every poll;onMatchfires once). Pair negative assertions withthenorthenContinually, notthenEventually, which passes trivially on the first poll. - MCP server in the CLI.
kensa mcpruns a Model Context Protocol server over stdio, giving an AI agent structured access to your test results. Four tools read a completed run (list_tests,list_failures,get_test,failure_evidence), so a failure reaches the agent as the Given/When/Then sentence Kensa parsed from your source rather than a stack trace it has to reverse-engineer. A fifth,style_profile, catalogues how the project writes Kensa tests (framework, fixture containers, MatcherFields, stub helpers, conventions and an exemplar) so a proposed fix follows your idiom. The bundle argument accepts a single bundle, a site-mode root, a test folder name from.kensa-properties, or nothing at all when only one folder is configured. Registration and usage are documented on kensa.dev.
Fixes:
- Expandable sentence hover popup sizes to its content. The hover preview was a fixed 450px wide, forcing ugly wrapping of the nested sentences it previews. It now grows to fit its content, keeping 450px as a minimum and capping at the available viewport width; a malformed max-width class on the multiline parameter block was also repaired (#176).
- Expandable sentence parameter names are tokenised. Parameters shown beside an expandable sentence rendered identifier names raw (
withConversationId = value). Identifiers in the parameter list now pass through the same token scanner as a normal sentence — camel-split into words, with protected phrases and acronyms honoured (with conversation id = value) (#177). - Test card corners no longer bleed. Test headers showed square corners outside the card's rounded border — all four when collapsed, where the header is the whole card. The card cannot clip with
overflow-hiddenbecause that stops the sticky parameter matrix pinning, so the header now carries its own matching radius: full when collapsed, top-only when expanded, where the body already rounds its bottom (#175). - Sequence and component diagrams render correctly in Safari. A message label containing consecutive spaces (e.g. from interaction naming with an empty segment) corrupted in Safari into interleaved, overlapping letters: XML whitespace collapsing renders the run as one space, but PlantUML computes
textLengthfor the raw string, and WebKit reconciles the mismatch underlengthAdjust="spacing"by overlapping glyph runs. Rendered SVGs now uselengthAdjust="spacingAndGlyphs", which WebKit lays out correctly and leaves Chrome visually unchanged (#174). - Given/When/Then keywords recognised in expandable sentence names. An
@ExpandableSentence(or nested sentence) call likethenAllTheVerificationsAreCorrect()rendered its whole name as one flat header — keyword scanning was disabled on that path and token types were discarded. The leading keyword is now emitted as its own keyword token (title-cased, rendered blue,whenevernormalising toWhen) ahead of the expandable header; expandables not at the start of a sentence are unchanged (#173).
Changed:
- Kotlin 2.4.10, Gradle 9.6.1. Toolchain bump from Kotlin 2.4.0 / Gradle 9.5.1; no API changes. Consumers using the build plugins get the matching compiler-plugin pairing via the next build-plugins release.