Skip to content

Commit

Permalink
chore: roll 1.45.0 (#1609)
Browse files Browse the repository at this point in the history
  • Loading branch information
yury-s authored Jun 25, 2024
1 parent a08ab2d commit e4828d0
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 85 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Playwright is a Java library to automate [Chromium](https://www.chromium.org/Hom

| | Linux | macOS | Windows |
| :--- | :---: | :---: | :---: |
| Chromium <!-- GEN:chromium-version -->127.0.6533.5<!-- GEN:stop --> | :white_check_mark: | :white_check_mark: | :white_check_mark: |
| Chromium <!-- GEN:chromium-version -->127.0.6533.17<!-- GEN:stop --> | :white_check_mark: | :white_check_mark: | :white_check_mark: |
| WebKit <!-- GEN:webkit-version -->17.4<!-- GEN:stop --> ||||
| Firefox <!-- GEN:firefox-version -->127.0<!-- GEN:stop --> | :white_check_mark: | :white_check_mark: | :white_check_mark: |

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -279,14 +279,12 @@ public CloseOptions setReason(String reason) {
}
class ExposeBindingOptions {
/**
* Whether to pass the argument as a handle, instead of passing by value. When passing a handle, only one argument is
* supported. When passing by value, multiple arguments are supported.
* @deprecated This option will be removed in the future.
*/
public Boolean handle;

/**
* Whether to pass the argument as a handle, instead of passing by value. When passing a handle, only one argument is
* supported. When passing by value, multiple arguments are supported.
* @deprecated This option will be removed in the future.
*/
public ExposeBindingOptions setHandle(boolean handle) {
this.handle = handle;
Expand Down Expand Up @@ -723,21 +721,6 @@ default List<Cookie> cookies() {
* }
* }</pre>
*
* <p> An example of passing an element handle:
* <pre>{@code
* context.exposeBinding("clicked", (source, args) -> {
* ElementHandle element = (ElementHandle) args[0];
* System.out.println(element.textContent());
* return null;
* }, new BrowserContext.ExposeBindingOptions().setHandle(true));
* page.setContent("" +
* "<script>\n" +
* " document.addEventListener('click', event => window.clicked(event.target));\n" +
* "</script>\n" +
* "<div>Click me</div>\n" +
* "<div>Or click me</div>\n");
* }</pre>
*
* @param name Name of the function on the window object.
* @param callback Callback function that will be called in the Playwright's context.
* @since v1.8
Expand Down Expand Up @@ -785,21 +768,6 @@ default void exposeBinding(String name, BindingCallback callback) {
* }
* }</pre>
*
* <p> An example of passing an element handle:
* <pre>{@code
* context.exposeBinding("clicked", (source, args) -> {
* ElementHandle element = (ElementHandle) args[0];
* System.out.println(element.textContent());
* return null;
* }, new BrowserContext.ExposeBindingOptions().setHandle(true));
* page.setContent("" +
* "<script>\n" +
* " document.addEventListener('click', event => window.clicked(event.target));\n" +
* "</script>\n" +
* "<div>Click me</div>\n" +
* "<div>Or click me</div>\n");
* }</pre>
*
* @param name Name of the function on the window object.
* @param callback Callback function that will be called in the Playwright's context.
* @since v1.8
Expand Down
33 changes: 18 additions & 15 deletions playwright/src/main/java/com/microsoft/playwright/Clock.java
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,8 @@ default void install() {
*
* <p> <strong>Usage</strong>
* <pre>{@code
* page.clock().pauseAt(Instant.parse("2020-02-02"));
* SimpleDateFormat format = new SimpleDateFormat("yyy-MM-dd");
* page.clock().pauseAt(format.parse("2020-02-02"));
* page.clock().pauseAt("2020-02-02");
* }</pre>
*
Expand All @@ -187,7 +188,8 @@ default void install() {
*
* <p> <strong>Usage</strong>
* <pre>{@code
* page.clock().pauseAt(Instant.parse("2020-02-02"));
* SimpleDateFormat format = new SimpleDateFormat("yyy-MM-dd");
* page.clock().pauseAt(format.parse("2020-02-02"));
* page.clock().pauseAt("2020-02-02");
* }</pre>
*
Expand All @@ -205,7 +207,8 @@ default void install() {
*
* <p> <strong>Usage</strong>
* <pre>{@code
* page.clock().pauseAt(Instant.parse("2020-02-02"));
* SimpleDateFormat format = new SimpleDateFormat("yyy-MM-dd");
* page.clock().pauseAt(format.parse("2020-02-02"));
* page.clock().pauseAt("2020-02-02");
* }</pre>
*
Expand All @@ -223,8 +226,8 @@ default void install() {
*
* <p> <strong>Usage</strong>
* <pre>{@code
* page.clock().setFixedTime(Instant.now());
* page.clock().setFixedTime(Instant.parse("2020-02-02"));
* page.clock().setFixedTime(new Date());
* page.clock().setFixedTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
* page.clock().setFixedTime("2020-02-02");
* }</pre>
*
Expand All @@ -237,8 +240,8 @@ default void install() {
*
* <p> <strong>Usage</strong>
* <pre>{@code
* page.clock().setFixedTime(Instant.now());
* page.clock().setFixedTime(Instant.parse("2020-02-02"));
* page.clock().setFixedTime(new Date());
* page.clock().setFixedTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
* page.clock().setFixedTime("2020-02-02");
* }</pre>
*
Expand All @@ -251,8 +254,8 @@ default void install() {
*
* <p> <strong>Usage</strong>
* <pre>{@code
* page.clock().setFixedTime(Instant.now());
* page.clock().setFixedTime(Instant.parse("2020-02-02"));
* page.clock().setFixedTime(new Date());
* page.clock().setFixedTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
* page.clock().setFixedTime("2020-02-02");
* }</pre>
*
Expand All @@ -265,8 +268,8 @@ default void install() {
*
* <p> <strong>Usage</strong>
* <pre>{@code
* page.clock().setSystemTime(Instant.now());
* page.clock().setSystemTime(Instant.parse("2020-02-02"));
* page.clock().setSystemTime(new Date());
* page.clock().setSystemTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
* page.clock().setSystemTime("2020-02-02");
* }</pre>
*
Expand All @@ -278,8 +281,8 @@ default void install() {
*
* <p> <strong>Usage</strong>
* <pre>{@code
* page.clock().setSystemTime(Instant.now());
* page.clock().setSystemTime(Instant.parse("2020-02-02"));
* page.clock().setSystemTime(new Date());
* page.clock().setSystemTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
* page.clock().setSystemTime("2020-02-02");
* }</pre>
*
Expand All @@ -291,8 +294,8 @@ default void install() {
*
* <p> <strong>Usage</strong>
* <pre>{@code
* page.clock().setSystemTime(Instant.now());
* page.clock().setSystemTime(Instant.parse("2020-02-02"));
* page.clock().setSystemTime(new Date());
* page.clock().setSystemTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
* page.clock().setSystemTime("2020-02-02");
* }</pre>
*
Expand Down
36 changes: 2 additions & 34 deletions playwright/src/main/java/com/microsoft/playwright/Page.java
Original file line number Diff line number Diff line change
Expand Up @@ -1042,14 +1042,12 @@ public EvalOnSelectorOptions setStrict(boolean strict) {
}
class ExposeBindingOptions {
/**
* Whether to pass the argument as a handle, instead of passing by value. When passing a handle, only one argument is
* supported. When passing by value, multiple arguments are supported.
* @deprecated This option will be removed in the future.
*/
public Boolean handle;

/**
* Whether to pass the argument as a handle, instead of passing by value. When passing a handle, only one argument is
* supported. When passing by value, multiple arguments are supported.
* @deprecated This option will be removed in the future.
*/
public ExposeBindingOptions setHandle(boolean handle) {
this.handle = handle;
Expand Down Expand Up @@ -4629,21 +4627,6 @@ default JSHandle evaluateHandle(String expression) {
* }
* }</pre>
*
* <p> An example of passing an element handle:
* <pre>{@code
* page.exposeBinding("clicked", (source, args) -> {
* ElementHandle element = (ElementHandle) args[0];
* System.out.println(element.textContent());
* return null;
* }, new Page.ExposeBindingOptions().setHandle(true));
* page.setContent("" +
* "<script>\n" +
* " document.addEventListener('click', event => window.clicked(event.target));\n" +
* "</script>\n" +
* "<div>Click me</div>\n" +
* "<div>Or click me</div>\n");
* }</pre>
*
* @param name Name of the function on the window object.
* @param callback Callback function that will be called in the Playwright's context.
* @since v1.8
Expand Down Expand Up @@ -4694,21 +4677,6 @@ default void exposeBinding(String name, BindingCallback callback) {
* }
* }</pre>
*
* <p> An example of passing an element handle:
* <pre>{@code
* page.exposeBinding("clicked", (source, args) -> {
* ElementHandle element = (ElementHandle) args[0];
* System.out.println(element.textContent());
* return null;
* }, new Page.ExposeBindingOptions().setHandle(true));
* page.setContent("" +
* "<script>\n" +
* " document.addEventListener('click', event => window.clicked(event.target));\n" +
* "</script>\n" +
* "<div>Click me</div>\n" +
* "<div>Or click me</div>\n");
* }</pre>
*
* @param name Name of the function on the window object.
* @param callback Callback function that will be called in the Playwright's context.
* @since v1.8
Expand Down
2 changes: 1 addition & 1 deletion scripts/DRIVER_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.45.0-beta-1718733727000
1.45.0

0 comments on commit e4828d0

Please sign in to comment.