public class ZoneddatetimeKt
| Modifier and Type | Method and Description |
|---|---|
static Matcher<java.time.ZonedDateTime> |
atSameZone(java.time.ZonedDateTime $receiver)
Matcher that uses
actual timezone on the expected ZonedDateTime |
static Matcher<java.time.ZonedDateTime> |
beInTodayZDT() |
static void |
shouldBeToday(java.time.ZonedDateTime $receiver)
Asserts that the ZonedDateTime has a date component of today
|
static void |
shouldNotBeToday(java.time.ZonedDateTime $receiver)
Asserts that the ZonedDateTime does not have a date component of today
|
public static Matcher<java.time.ZonedDateTime> beInTodayZDT()
public static void shouldNotBeToday(java.time.ZonedDateTime $receiver)
Asserts that the ZonedDateTime does not have a date component of today
ZonedDateTime.of(2009, Month.APRIL, 2,2,2).shouldNotBeToday() // Assertion passes
public static void shouldBeToday(java.time.ZonedDateTime $receiver)
Asserts that the ZonedDateTime has a date component of today
ZonedDateTime.now().shouldBeToday() // Assertion passes
public static Matcher<java.time.ZonedDateTime> atSameZone(java.time.ZonedDateTime $receiver)
Matcher that uses actual timezone on the expected ZonedDateTime
ZonedDateTime.of(2019, 12, 10, 10, 0, 0, 0, ZoneOffset.UTC) shouldBe
ZonedDateTime.of(2019, 12, 10, 4, 0, 0, 0, ZoneId.of("America/Chicago")).atSameZone() // Assertion passes