playwright-java
playwright-java copied to clipboard
[Feature]: Change java.util.Date to java.time.LocalDateTime in Clock API
🚀 Feature Request
Implementing code using Clock is not as pleasant as it could be.
Example
Now, I have to write something like this:
Instant instant = Instant.now().plus(10, ChronoUnit.MINUTES);
Date date = Date.from(instant);
page.clock().setSystemTime(date)
But I would like to write just like this:
page.clock().setSystemTime(LocalDateTime.now().plusMinutes(10))
Motivation
To use more modern and more convenient java.
Definitely 100% support for this. Please don't use the very old and broken Date API, modern code should always use the java.time API.