Skip to content

0.24.0

Latest

Choose a tag to compare

@agourlay agourlay released this 29 Apr 19:05
· 205 commits to master since this release
d3cbbb9

This release ships a brand-new documentation website and tightens up a few rough edges in the matchers and DSL.

This means a handful of breaking changes so please skim the Migration notes below before upgrading.

Migration notes

Most users should see little or no impact, but a few changes can flip previously green tests to red without a compile error:

  • <any-integer> no longer matches floats. Any assertion using <any-integer> against a JSON field that holds a floating-point value (e.g. 1.5, or 0.1 serialized as a float) will now fail.
    • Switch to the new <any-number> matcher when you want to accept any numeric value.
  • <any-alphanum-string> no longer matches empty strings.
    • Tests relying on the previous (buggy) behavior will start failing.
  • for_all builder is now tupled. For arities 2-6, replace builder(a)(b)… with builder(a, b, …) at call sites.
  • AssertStep must be non-blocking. It now runs on the compute pool via IO.delay instead of IO.interruptible.
  • cornichon-scalatest and cornichon-kafka modules are dropped.
    • ScalaTest users should migrate to cornichon-test-framework.
    • There is no alternative to cornichon-kafka outside of copying the DSL.

Breaking changes

  • Drop cornichon-kafka module e69d3a9e
  • Drop cornichon-scalatest module a6be3600
  • AssertStep now runs on the compute pool via IO.delay (was IO.interruptible).
    • Assertions must be non-blocking; move blocking work (Thread.sleep, network calls, etc.) to EffectStep, otherwise
      Eventually/RepeatConcurrently cancellation will not interrupt them 42f0efee
  • for_all builder signature changed from curried (A => B => Step) to tupled ((A, B) => Step) for arities 2-6 — call sites must be updated cf1b5656
  • Matcher any-integer no longer matches floating-point numbers (predicate is now _.asNumber.flatMap(_.toInt).isDefined)
    • use the new any-number matcher to accept any numeric value fd3cabe5
  • Matcher any-alphanum-string no longer accepts empty strings 4f26735d

Improvements

  • Add timeout on WithinStep 101c2697
  • Session now handles negative indexes 26648b1f
  • New anyNumber matcher for any numeric value fd3cabe5
  • Model checker fails on negative weight ed93f801
  • Display all errors from afterFeature hooks instead of only the first a84a8c85
  • Do not short-circuit when running afterFeature hooks 5e2c49de
  • Improve error reporting for non-JSON payload 0d7c6b96
  • Harden HTTP mock server 00aea4c1

Bug fixes

  • Fix transition probability in model checker 810a43c1
  • Fix cleanup steps propagation in wrapper steps (RepeatStep, RetryMaxStep) 0f3a2a2e
  • Fix Session get throwing IndexOutOfBoundsException a15dc763
  • Fix datatable detector acafc764
  • Fix WithinStep failure log 23a2ffd4

Performance

  • Avoid reallocating in JSON folder 0b442853
  • Optimize JsonMapper 506b8598
  • Optimize parseDslStringJson e52c566d
  • Optimize findAllPathWithStringValue now builds Vector[JsonPathOperation] 6edc401b
  • Optimize Matcher path finder 6120181e
  • Avoid allocating Resolvable form when there are no placeholders 7e61c95c
  • Configure request duplicates once 343e2260

Documentation

  • Migrate site from sbt-microsite to sbt-laika 11377c9d
  • Major restructure with new sections (syntax reference, performance tuning, errors page & braceless syntax)
  • Refreshed landing page and quickstart, cleaner light mode, cross-page links, callout sections

Internal

  • Remove pureconfig dependency in favor of simpler manual config loading cf85ecb9
  • Adopt scalafmt for the codebase, with formatting checks enforced on CI d8c6dec1, 21134d87

Dependency updates

  • cats-effect 3.6.3 → 3.7.0
  • fs2 3.12.2 → 3.13.0
  • http4s 0.23.33 → 0.23.34
  • sangria 4.2.15 → 4.2.18
  • diffson-circe 4.6.1 → 4.7.0
  • decline 2.5.0 → 2.6.2
  • munit 1.2.1 → 1.3.0