Skip to content

Releases: cashapp/turbine

1.2.0

16 Oct 14:24
Compare
Choose a tag to compare

Added

  • Add wasmWasi target.

1.1.0

06 Mar 14:35
Compare
Choose a tag to compare

Changed

  • Add wasmJs target, remove iosArm32 and watchosX86 targets.
  • Throw unconsumed events if scope is externally canceled.

1.0.0

21 Jun 04:25
Compare
Choose a tag to compare

Added

  • Add turbineScope DSL function which is now required for using testIn. This ensures that exceptions which occur within the test are no longer potentially lost.

Changed

  • Failed Turbines which occur while testing a Flow (using test { }) will now have their failures eagerly reported.
  • Build with Kotlin 1.8.22 and kotlinx.coroutines 1.7.1. Note: Future releases will not highlight the Kotlin or coroutines version unless important for some other reason.

0.13.0

11 May 15:57
Compare
Choose a tag to compare

Added

  • New Kotlin/Native targets:
    • androidNativeArm32
    • androidNativeArm64
    • androidNativeX86
    • androidNativeX64
    • linuxArm64
    • watchosDeviceArm64

Changed

  • Build with Kotlin 1.8.21

Note: This version has a transitive dependency on kotlinx.coroutines 1.7.0. If you are an Android user, you should be depending on kotlinx.coroutines 1.7.1 which graciously fixes a binary incompatibility with a Compose testing artifact (because they failed to heed its opt-in annotation which indicated that it was not a stable API).

0.12.3

30 Mar 12:45
Compare
Choose a tag to compare

Fixed

  • Ensure JVM classes target Java 8 rather than implicitly using the build JDK version.

0.12.2

30 Mar 03:22
Compare
Choose a tag to compare

Changed

  • The default wall-clock timeout used to wait for an event has been increased from 1s to 3s.

Fixed

  • The exception thrown when no events have been received now includes the original timeout exception as its cause. This ensures the stacktrace contains the caller file and line information.
  • Ensure expectNoEvents() fails if a completion or exception event occurred.
  • Differentiate timeout and cancellation exceptions thrown from Turbine's own event timeout (which are thrown) from those which occur within the flow under test (which are available via awaitError()).

0.12.1

03 Nov 20:39
Compare
Choose a tag to compare

Changed

  • Build with Kotlin 1.7.20

Fixed

  • takeItem() no longer throws an exception when returning a null value.
  • await-prefixed methods no longer interfere with virtual time control from a TestScheduler (such as inside runTest).

0.12.0

11 Oct 20:49
Compare
Choose a tag to compare

Added

  • Support specifying a human-readable name for differentiating the failures of multiple Turbines

Fixed

  • Properly catch all Throwable subtypes from failures in flows and channels as events.

0.11.0

21 Sep 13:32
Compare
Choose a tag to compare

Added

  • Restore timeout support. By default a 1-second timeout will be enforced when awaiting an event. This can be customized by supplying a timeout argument or by using the withTurbineTimeout wrapper function. Timeouts will always use wall clock time even when using a virtual time dispatcher.

Changed

  • When runTest (or any TestCoroutineScheduler) is in use, switch to the UnconfinedTestScheduler internally to ensure virtual time remains working.

0.10.0

14 Sep 20:46
Compare
Choose a tag to compare

Changed

  • Remove ReceiveTurbine.ignoreRemainingEvents from public API.

Fixed

  • Restore usage of Unconfined dispatcher preventing value conflation (as much as possible) so that intermediate values can always be observed.