final case class Test(clockState: Atomic[Data], live: Live, annotations: Annotations, warningState: Synchronized[WarningData], suspendedWarningState: Synchronized[SuspendedWarningData]) extends TestClock with TestClockPlatformSpecific with Product with Serializable
- Alphabetic
- By Inheritance
- Test
- Product
- Equals
- TestClockPlatformSpecific
- TestClock
- Restorable
- Clock
- Serializable
- Serializable
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
- new Test(clockState: Atomic[Data], live: Live, annotations: Annotations, warningState: Synchronized[WarningData], suspendedWarningState: Synchronized[SuspendedWarningData])
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
adjust(duration: zio.Duration)(implicit trace: Trace): UIO[Unit]
Increments the current clock time by the specified duration.
-
def
adjustWith[R, E, A](duration: zio.Duration)(zio: ZIO[R, E, A])(implicit trace: Trace): ZIO[R, E, A]
Increments the current clock time by the specified duration.
- val annotations: Annotations
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
- val clockState: Atomic[Data]
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
currentDateTime(implicit trace: Trace): UIO[OffsetDateTime]
Returns the current clock time as an
OffsetDateTime.Returns the current clock time as an
OffsetDateTime.- Definition Classes
- Test → Clock
-
def
currentTime(unit: ⇒ ChronoUnit)(implicit trace: Trace, d: DummyImplicit): UIO[Long]
- Definition Classes
- Test → Clock
-
def
currentTime(unit: ⇒ TimeUnit)(implicit trace: Trace): UIO[Long]
Returns the current clock time in the specified time unit.
Returns the current clock time in the specified time unit.
- Definition Classes
- Test → Clock
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
instant(implicit trace: Trace): UIO[Instant]
Returns the current clock time as an
Instant.Returns the current clock time as an
Instant.- Definition Classes
- Test → Clock
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
javaClock(implicit trace: Trace): UIO[java.time.Clock]
Constructs a
java.time.Clockbacked by theClockservice.Constructs a
java.time.Clockbacked by theClockservice.- Definition Classes
- Test → Clock
- val live: Live
-
def
localDateTime(implicit trace: Trace): UIO[LocalDateTime]
Returns the current clock time as a
LocalDateTime.Returns the current clock time as a
LocalDateTime.- Definition Classes
- Test → Clock
-
def
nanoTime(implicit trace: Trace): UIO[Long]
Returns the current clock time in nanoseconds.
Returns the current clock time in nanoseconds.
- Definition Classes
- Test → Clock
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
save(implicit trace: Trace): UIO[UIO[Unit]]
Saves the
TestClock's current state in an effect which, when run, will restore theTestClockstate to the saved stateSaves the
TestClock's current state in an effect which, when run, will restore theTestClockstate to the saved state- Definition Classes
- Test → Restorable
-
def
scheduler(implicit trace: Trace): UIO[Scheduler]
- Definition Classes
- TestClockPlatformSpecific
-
def
setTime(instant: Instant)(implicit trace: Trace): UIO[Unit]
Sets the current clock time to the specified
Instant. -
def
setTimeZone(zone: ZoneId)(implicit trace: Trace): UIO[Unit]
Sets the time zone to the specified time zone.
-
def
sleep(duration: ⇒ zio.Duration)(implicit trace: Trace): UIO[Unit]
Semantically blocks the current fiber until the clock time is equal to or greater than the specified duration.
Semantically blocks the current fiber until the clock time is equal to or greater than the specified duration. Once the clock time is adjusted to on or after the duration, the fiber will automatically be resumed.
- Definition Classes
- Test → Clock
-
def
sleeps(implicit trace: Trace): UIO[List[Instant]]
Returns a list of the times at which all queued effects are scheduled to resume.
-
def
supervisedFibers(implicit trace: Trace): UIO[SortedSet[Fiber.Runtime[Any, Any]]]
Returns a set of all fibers in this test.
- val suspendedWarningState: Synchronized[SuspendedWarningData]
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
timeZone(implicit trace: Trace): UIO[ZoneId]
Returns the time zone.
-
val
unsafe: UnsafeAPI
- Definition Classes
- Test → Clock
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- val warningState: Synchronized[WarningData]