Skip to content

Commit 328f145

Browse files
fix find element and update readme
1 parent 2a90365 commit 328f145

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,12 @@ driver.findElementByAccessibilityId("login").sendKeys('Hello');
5757
Server logs will be as below:
5858

5959
```
60+
[Appium] Plugins which can handle cmd 'findElement': element-wait (sessionless)
6061
[Appium] Plugin element-wait (sessionless) is now handling cmd 'findElement'
61-
[Plugin [element-wait (sessionless)]] Retrying to find element with accessibility id strategy for login selector
62-
[Plugin [element-wait (sessionless)]] Retrying to find element with accessibility id strategy for login selector
63-
[Plugin [element-wait (sessionless)]] Retrying to find element with accessibility id strategy for login selector
62+
[Plugin [element-wait (sessionless)]] Waiting to find element with accessibility id strategy for login selector
63+
[Plugin [element-wait (sessionless)]] Waiting to find element with accessibility id strategy for login selector
64+
[Plugin [element-wait (sessionless)]] Waiting to find element with accessibility id strategy for login selector
65+
[Plugin [element-wait (sessionless)]] Waiting to find element with accessibility id strategy for login selector
6466
[Plugin [element-wait (sessionless)]] Element with accessibility id strategy for login selector found.
6567
[Plugin [element-wait (sessionless)]] Checking if login element is displayed
6668
[Plugin [element-wait (sessionless)]] login element is displayed.

src/plugin.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export default class WaitCommandPlugin extends BasePlugin {
99
const locatorArgs = JSON.parse(JSON.stringify(args));
1010
this.strategy = locatorArgs[0];
1111
this.selector = locatorArgs[1];
12-
await this._find(locatorArgs);
12+
await this._find();
1313
await this._elementDisplayed();
1414
originalRes = await next();
1515
retryCount = 0;
@@ -22,7 +22,7 @@ export default class WaitCommandPlugin extends BasePlugin {
2222
if (element.value.error) {
2323
if (retryCount !== this._getTimeout()) {
2424
this.logger.info(
25-
`Waiting for find element with ${this.strategy} strategy for ${this.selector} selector`
25+
`Waiting to find element with ${this.strategy} strategy for ${this.selector} selector`
2626
);
2727
retryCount++;
2828
await this._find();

0 commit comments

Comments
 (0)