Skip to content

Commit

Permalink
Adds prefab values for java.time.Clock
Browse files Browse the repository at this point in the history
  • Loading branch information
sullis authored and jqno committed Jan 19, 2021
1 parent 0d849e9 commit b43d8e8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
Expand Up @@ -218,6 +218,12 @@ private void addDateTimeClasses() {
new GregorianCalendar(2010, 7, 5),
new GregorianCalendar(2010, 7, 4)
);
addValues(
Clock.class,
Clock.systemUTC(),
Clock.system(ZoneId.of("-10")),
Clock.systemUTC()
);
addValues(Date.class, new Date(0), new Date(1), new Date(0));
addValues(
DateFormat.class,
Expand Down
Expand Up @@ -522,6 +522,7 @@ static final class Java8ApiClassesContainer {
private final CompletableFuture<?> completableFuture;
private final StampedLock stampedLock;
private final Supplier<?> supplier;
private final Clock clock;
private final Duration duration;
private final Instant instant;
private final MonthDay monthDay;
Expand All @@ -546,6 +547,7 @@ public Java8ApiClassesContainer(
CompletableFuture<?> completableFuture,
StampedLock stampedLock,
Supplier<?> supplier,
Clock clock,
Duration duration,
Instant instant,
MonthDay monthDay,
Expand All @@ -569,6 +571,7 @@ public Java8ApiClassesContainer(
this.completableFuture = completableFuture;
this.stampedLock = stampedLock;
this.supplier = supplier;
this.clock = clock;
this.duration = duration;
this.instant = instant;
this.monthDay = monthDay;
Expand Down

0 comments on commit b43d8e8

Please sign in to comment.