Packages

  • package root
    Definition Classes
    root
  • package zio
    Definition Classes
    root
  • package test

    _ZIO Test_ is a featherweight testing library for effectful programs.

    _ZIO Test_ is a featherweight testing library for effectful programs.

    The library imagines every spec as an ordinary immutable value, providing tremendous potential for composition. Thanks to tight integration with ZIO, specs can use resources (including those requiring disposal), have well- defined linear and parallel semantics, and can benefit from a host of ZIO combinators.

    import zio.test._
    import zio.clock.nanoTime
    import Predicate.gt
    
    object MyTest extends DefaultRunnableSpec {
      suite("clock") {
        testM("time is non-zero") {
          assertM(nanoTime, gt(0))
        }
      }
    }
    Definition Classes
    zio
  • package mock
    Definition Classes
    test
  • MockClock
  • MockConsole
  • MockEnvironment
  • MockRandom
  • MockScheduler
  • MockSystem
p

zio.test

mock

package mock

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. mock
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. trait MockClock extends Clock
  2. trait MockConsole extends Console
  3. case class MockEnvironment(clock: Mock, console: Mock, random: Mock, scheduler: MockScheduler, system: Mock, blocking: Service[Any]) extends Blocking with MockClock with MockConsole with MockRandom with Scheduler with MockSystem with Product with Serializable
  4. trait MockRandom extends Random
  5. final case class MockScheduler(ref: Ref[Data], runtime: Runtime[Clock]) extends Service[Any] with Product with Serializable

    Implementation of Scheduler.Service for testing.

    Implementation of Scheduler.Service for testing. The passed Ref[TestClock.Data] will be used to determine when to run the scheduled runnables. Make sure to call shutdown() to force execution of all remaining tasks.

  6. trait MockSystem extends System

Value Members

  1. val mockEnvironmentManaged: Managed[Nothing, MockEnvironment]
  2. object MockClock extends Serializable
  3. object MockConsole extends Serializable
  4. object MockEnvironment extends Serializable
  5. object MockRandom extends Serializable
  6. object MockScheduler extends Serializable
  7. object MockSystem extends Serializable

Inherited from AnyRef

Inherited from Any

Ungrouped