Skip to content

Commit bdc5c67

Browse files
committed
DOC: Autogenerate and update documentation
1 parent 3f7d2bd commit bdc5c67

File tree

4 files changed

+271
-188
lines changed

4 files changed

+271
-188
lines changed

docs/helpers/Appium.md

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -872,16 +872,21 @@ Returns **[Promise][6]\<void>** Appium: support both Android and iOS
872872
Appends text to a input field or textarea.
873873
Field is located by name, label, CSS or XPath
874874

875+
The third parameter is an optional context (CSS or XPath locator) to narrow the search.
876+
875877
```js
876878
I.appendField('#myTextField', 'appended');
877879
// typing secret
878880
I.appendField('password', secret('123456'));
881+
// within a context
882+
I.appendField('name', 'John', '.form-container');
879883
```
880884

881885
#### Parameters
882886

883887
* `field` **([string][5] | [object][11])** located by label|name|CSS|XPath|strict locator
884888
* `value` **[string][5]** text value to append.
889+
* `context` **([string][5]? | [object][11])** (optional, `null` by default) element located by CSS | XPath | strict locator. (optional, default `null`)
885890

886891
Returns **void** automatically synchronized promise through #recorder
887892

@@ -890,7 +895,7 @@ Returns **void** automatically synchronized promise through #recorder
890895
Selects a checkbox or radio button.
891896
Element is located by label or name or CSS or XPath.
892897

893-
The second parameter is a context (CSS or XPath locator) to narrow the search.
898+
The second parameter is an optional context (CSS or XPath locator) to narrow the search.
894899

895900
```js
896901
I.checkOption('#agree');
@@ -979,15 +984,20 @@ Returns **void** automatically synchronized promise through #recorder
979984
Checks that value of input field or textarea doesn't equal to given value
980985
Opposite to `seeInField`.
981986

987+
The third parameter is an optional context (CSS or XPath locator) to narrow the search.
988+
982989
```js
983990
I.dontSeeInField('email', 'user@user.com'); // field by name
984991
I.dontSeeInField({ css: 'form input.email' }, 'user@user.com'); // field by CSS
992+
// within a context
993+
I.dontSeeInField('Name', 'old_value', '.form-container');
985994
```
986995

987996
#### Parameters
988997

989998
* `field` **([string][5] | [object][11])** located by label|name|CSS|XPath|strict locator.
990999
* `value` **([string][5] | [object][11])** value to check.
1000+
* `context` **([string][5]? | [object][11])** (optional, `null` by default) element located by CSS | XPath | strict locator. (optional, default `null`)
9911001

9921002
Returns **void** automatically synchronized promise through #recorder
9931003

@@ -1013,7 +1023,7 @@ Returns **void** automatically synchronized promise through #recorder
10131023
Fills a text field or textarea, after clearing its value, with the given string.
10141024
Field is located by name, label, CSS, or XPath.
10151025

1016-
The third parameter is a context (CSS or XPath locator) to narrow the search.
1026+
The third parameter is an optional context (CSS or XPath locator) to narrow the search.
10171027

10181028
```js
10191029
// by label
@@ -1222,17 +1232,22 @@ Returns **void** automatically synchronized promise through #recorder
12221232
Checks that the given input field or textarea equals to given value.
12231233
For fuzzy locators, fields are matched by label text, the "name" attribute, CSS, and XPath.
12241234

1235+
The third parameter is an optional context (CSS or XPath locator) to narrow the search.
1236+
12251237
```js
12261238
I.seeInField('Username', 'davert');
12271239
I.seeInField({css: 'form textarea'},'Type your comment here');
12281240
I.seeInField('form input[type=hidden]','hidden_value');
12291241
I.seeInField('#searchform input','Search');
1242+
// within a context
1243+
I.seeInField('Name', 'John', '.form-container');
12301244
```
12311245

12321246
#### Parameters
12331247

12341248
* `field` **([string][5] | [object][11])** located by label|name|CSS|XPath|strict locator.
12351249
* `value` **([string][5] | [object][11])** value to check.
1250+
* `context` **([string][5]? | [object][11])** (optional, `null` by default) element located by CSS | XPath | strict locator. (optional, default `null`)
12361251

12371252
Returns **void** automatically synchronized promise through #recorder
12381253

@@ -1260,7 +1275,7 @@ Selects an option in a drop-down select.
12601275
Field is searched by label | name | CSS | XPath.
12611276
Option is selected by visible text or by value.
12621277

1263-
The third parameter is a context (CSS or XPath locator) to narrow the search.
1278+
The third parameter is an optional context (CSS or XPath locator) to narrow the search.
12641279

12651280
```js
12661281
I.selectOption('Choose Plan', 'Monthly'); // select by label

0 commit comments

Comments
 (0)