Skip to content

Commit 9afc8e2

Browse files
committed
docs(rules): add emojis
1 parent 6205a05 commit 9afc8e2

34 files changed

+74
-68
lines changed

docs/rules/array-callback-return.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ it would not be detected as a violation. Look into having [`array-callback-retur
2525

2626
## Rule details
2727

28-
Any use of the following patterns are considered warnings:
28+
:thumbsdown: Any use of the following patterns are considered warnings:
2929

3030
```js
3131
element.all(by.css(".myclass")).filter(function() {
@@ -42,7 +42,7 @@ $$(".myclass").filter(a ? function() {} : function() {});
4242
$$(".myclass").filter(function(){ return function() {}; }())
4343
```
4444

45-
The following patterns are not warnings:
45+
:thumbsup: The following patterns are not warnings:
4646

4747
```js
4848
element.all(by.css(".myclass")).filter(function(elm) {

docs/rules/bare-element-finders.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ It is easy to forget to actually call an ElementFinder method and the rule would
1212
## Rule details
1313

1414

15-
Any use of the following patterns are considered warnings:
15+
:thumbsdown: Any use of the following patterns are considered warnings:
1616

1717
```js
1818
element(by.id('signin_submit_btn'));
@@ -27,7 +27,7 @@ $$(".class1").first().element(by.css(".class2"));
2727
$(".class1").$(".class2");
2828
```
2929

30-
The following patterns are not warnings:
30+
:thumbsup: The following patterns are not warnings:
3131

3232
```js
3333
element(by.id('signin_submit_btn')).click();

docs/rules/by-css-shortcut.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Recommend using `$` and `$$` shortcuts instead of `element(by.css())` and `eleme
66

77
The rule is disabled by default.
88

9-
Any use of the following patterns are considered warnings:
9+
:thumbsdown: Any use of the following patterns are considered warnings:
1010

1111
```js
1212
element(by.css(".class"));
@@ -15,7 +15,7 @@ element(by.id("id")).element(by.css(".class"));
1515
element(by.id("id")).all(by.css(".class"));
1616
```
1717

18-
The following patterns are not warnings:
18+
:thumbsup: The following patterns are not warnings:
1919

2020
```js
2121
$(".class");

docs/rules/correct-chaining.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ element(by.css('.parent')).all(by.css('.child'));
1717

1818
## Rule details
1919

20-
Any use of the following patterns are considered warnings:
20+
:thumbsdown: Any use of the following patterns are considered warnings:
2121

2222
```js
2323
element(by.css('.parent')).element.all(by.css('.child'));
@@ -26,7 +26,7 @@ element.all(by.css('.child')).first().element.all(by.css('.child'));
2626
$$('.parent').first().element.all(by.css('.child'));
2727
```
2828

29-
The following patterns are not warnings:
29+
:thumbsup: The following patterns are not warnings:
3030

3131
```js
3232
element(by.css('.parent')).all(by.css('.child'));

docs/rules/limit-selector-depth.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Number of nodes is configurable, default value is `5`.
2222

2323
This rule is based on [`css-selector-parser`](https://github.com/mdevils/node-css-selector-parser) parsing abilities.
2424

25-
Any use of the following patterns are considered warnings (with the default depth value of `5`):
25+
:thumbsdown: Any use of the following patterns are considered warnings (with the default depth value of `5`):
2626

2727
```js
2828
element(by.css(".content > table > tbody > tr:nth-child(2) > td.cell > input#email"));
@@ -31,7 +31,7 @@ $(".content > table > tbody > tr:nth-child(2) > td.cell > input#email");
3131
$$(".content > table > tbody > tr:nth-child(2) > td.cell > input#email");
3232
```
3333

34-
The following patterns are not warnings:
34+
:thumbsup: The following patterns are not warnings:
3535

3636
```js
3737
element(by.css(".myclass"));

docs/rules/missing-perform.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ Ensure `perform()` is called on `browser.actions()` chain of actions.
77
This rule triggers an error if there is no `perform()` at the end of the `browser.actions()` chain.
88
Note that there has to be at least one applied action to trigger the rule. In other words, `var actions = browser.actions();` is considered valid since it is quite a common pattern.
99

10-
The following patterns are considered errors:
10+
:thumbsdown: The following patterns are considered errors:
1111

1212
```js
1313
browser.actions().click();
1414
browser.actions().mouseMove(elm);
1515
```
1616

17-
The following patterns are not errors:
17+
:thumbsup: The following patterns are not errors:
1818

1919
```js
2020
var actions = browser.actions();

docs/rules/missing-wait-message.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ Ensure the timeout message is set when `browser.wait()` is called.
77
This rule triggers a warning if there is no message in case `browser.wait()` timeouts.
88
Having explicit timeout messages helps in debugging and troubleshooting the test failures.
99

10-
The following patterns are considered warnings:
10+
:thumbsdown: The following patterns are considered warnings:
1111

1212
```js
1313
browser.wait(EC.presenceOf(elm), 5000);
1414
browser.wait(EC.visibilityOf(elm), 5000);
1515
```
1616

17-
The following patterns are not warnings:
17+
:thumbsup: The following patterns are not warnings:
1818

1919
```js
2020
browser.wait(EC.presenceOf(elm), 5000, "The user menu is not present");

docs/rules/no-absolute-url.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ This helps to easily switch to a different target application URL by simply chan
77

88
## Rule details
99

10-
Any use of the following patterns are considered warnings:
10+
:thumbsdown: Any use of the following patterns are considered warnings:
1111

1212
```js
1313
browser.get("http://google.com");
1414
browser.driver.get("https://google.com");
1515
```
1616

17-
The following patterns are not warnings:
17+
:thumbsup: The following patterns are not warnings:
1818

1919
```js
2020
browser.get("login");

docs/rules/no-angular-attributes.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Ensure attributes used by Angular internally are not used to locate elements via
66

77
The rule would scan attributes used inside CSS selectors and would complain about any attribute that starts with `ng-` or `data-ng-` or `x-ng-`.
88

9-
Any use of the following patterns are considered warnings:
9+
:thumbsdown: Any use of the following patterns are considered warnings:
1010

1111
```js
1212
element(by.css("[ng-show=test]"));
@@ -20,7 +20,7 @@ element(by.id("id")).$$("[ng-blur^=expression], a[href^=/]");
2020
element(by.id("id")).$("[data-ng-pattern*='test']");
2121
```
2222

23-
The following patterns are not warnings:
23+
:thumbsup: The following patterns are not warnings:
2424

2525
```js
2626
element(by.css("input"));

docs/rules/no-angular-classes.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Current list of Angular classes this rule would complain about (based on the [CS
1616
* `ng-touched`
1717
* `ng-untouched`
1818

19-
Any use of the following patterns are considered warnings:
19+
:thumbsdown: Any use of the following patterns are considered warnings:
2020

2121
```js
2222
element(by.css(".ng-scope"));
@@ -30,7 +30,7 @@ element(by.id("id")).$$(".ng-touched.myclass");
3030
element(by.id("id")).$("input.ng-untouched");
3131
```
3232

33-
The following patterns are not warnings:
33+
:thumbsup: The following patterns are not warnings:
3434

3535
```js
3636
element(by.css(".myclass"));

docs/rules/no-array-finder-methods.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Here is the current list of methods the rule is looking for:
1010

1111
'first', 'last', 'get', 'filter', 'map', 'each', 'reduce', 'count'
1212

13-
Any use of the following patterns are considered warnings:
13+
:thumbsdown: Any use of the following patterns are considered warnings:
1414

1515
```js
1616
element(by.css(".class")).get(0);
@@ -25,7 +25,7 @@ $(".class1").element(by.css(".class2")).first();
2525
$(".class1").$(".class2").first();
2626
```
2727

28-
The following patterns are not warnings:
28+
:thumbsup: The following patterns are not warnings:
2929

3030
```js
3131
element.all(by.css(".class")).get(0);

docs/rules/no-bootstrap-classes.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Compare these classes with, for example, `product` or `itemPrice` classes - thes
99

1010
Current list of Bootstrap classes this rule would complain about can be viewed [here](../../lib/bootstrap-layout-classes.js) (hand-picked).
1111

12-
Any use of the following patterns are considered warnings:
12+
:thumbsdown: Any use of the following patterns are considered warnings:
1313

1414
```js
1515
element(by.css(".col-lg-12"));
@@ -23,7 +23,7 @@ element(by.id("id")).$$(".col-lg-offset-8.myclass");
2323
element(by.id("id")).$("input.col-lg-pull-8");
2424
```
2525

26-
The following patterns are not warnings:
26+
:thumbsup: The following patterns are not warnings:
2727

2828
```js
2929
element(by.css(".myclass"));

docs/rules/no-browser-driver.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@ The rule would warn if using `browser.driver` instead of using `browser` directl
44

55
## Rule details
66

7-
Any use of the following patterns are considered warnings:
7+
:thumbsdown: Any use of the following patterns are considered warnings:
88

99
```js
1010
browser.driver.sleep(2000);
1111
var driver = browser.driver;
1212
```
1313

14-
The following patterns are not warnings:
14+
:thumbsup: The following patterns are not warnings:
1515

1616
```js
1717
browser.sleep(1000);

docs/rules/no-browser-pause.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@ Ensure `browser.pause()` is not used.
77
`browser.pause()` usage is useful for debugging, but can cause problems in automated environments.
88
This rule would issue an error if `browser.pause()` is used.
99

10-
The following patterns are considered warnings:
10+
:thumbsdown: The following patterns are considered warnings:
1111

1212
```js
1313
browser.pause();
1414
```
1515

16-
The following patterns are not warnings:
16+
:thumbsup: The following patterns are not warnings:
1717

1818
```js
1919
browser.notPause();

docs/rules/no-browser-sleep.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ Ensure `browser.sleep()` is not used.
77
`browser.sleep()` usage is usually considered a bad practice and an Explicit Wait via the `browser.wait()` is suggested to be used instead.
88
This rule would issue a warning if `browser.sleep()` is used.
99

10-
The following patterns are considered warnings:
10+
:thumbsdown: The following patterns are considered warnings:
1111

1212
```js
1313
browser.sleep(10);
1414
browser.sleep(10000);
1515
```
1616

17-
The following patterns are not warnings:
17+
:thumbsup: The following patterns are not warnings:
1818

1919
```js
2020
SomeObject.sleep(10);

docs/rules/no-by-xpath.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,14 @@ Ensure `by.xpath` locator is not used.
66

77
According to the [Protractor's style guide](https://github.com/angular/protractor/blob/master/docs/style-guide.md#never-use-xpath), using `by.xpath` is considered a bad practice.
88

9-
The following patterns are considered warnings:
9+
:thumbsdown: The following patterns are considered warnings:
1010

1111
```js
1212
element(by.xpath("//a[starts-with(@href, 'something')]"));
1313
element.all(by.xpath("//a[starts-with(@href, 'something')]"));
1414
```
1515

16-
The following patterns are not warnings:
16+
:thumbsup: The following patterns are not warnings:
1717

1818
```js
1919
element(by.css("a[href^=something]"));

docs/rules/no-compound-classes.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Ensure that there are no compound class names (multiple space-delimited classes)
66

77
## Rule details
88

9-
Any use of the following patterns are considered errors:
9+
:thumbsdown: Any use of the following patterns are considered errors:
1010

1111
```js
1212
element(by.className("class1 class2"));
@@ -15,7 +15,7 @@ element(by.id("myid")).all(by.className("class1 class2 class3"));
1515
element(by.id("myid")).element(by.className("class1 class2 class3"));
1616
```
1717

18-
The following patterns are not errors:
18+
:thumbsup: The following patterns are not errors:
1919

2020
```js
2121
element(by.css("tag1 tag2"));

docs/rules/no-describe-selectors.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Ensure raw selectors are not used within `describe` blocks.
66

77
As described in [Protractor's documentation](https://github.com/angular/protractor/blob/master/docs/page-objects.md), it is recommended that query selectors be organized within Page Objects in order to keep code cleaner, more reusable, and easier to maintain.
88

9-
Any use of the following patterns are considered warnings:
9+
:thumbsdown: Any use of the following patterns are considered warnings:
1010

1111
```js
1212
describe(function () {
@@ -36,7 +36,7 @@ describe(function () {
3636
});
3737
```
3838

39-
The following patterns are not warnings:
39+
:thumbsup: The following patterns are not warnings:
4040

4141
```js
4242
var AngularHomepage = function() {

docs/rules/no-get-in-it.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,14 @@ The rule currently does not allow to configure the test function names and will
66

77
## Rule details
88

9-
Any use of the following patterns are considered warnings:
9+
:thumbsdown: Any use of the following patterns are considered warnings:
1010

1111
```js
1212
it("should do something", function() { browser.get("mypage"); });
1313
it("should do something", function() { browser.driver.get("mypage"); });
1414
```
1515

16-
The following patterns are not warnings:
16+
:thumbsup: The following patterns are not warnings:
1717

1818
```js
1919
beforeEach(function() { browser.get("mypage"); });

docs/rules/no-get-inner-outer-html.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ And, hence, [`Protractor` removed them as well in version 5.0.0](https://github.
55

66
## Rule details
77

8-
Any use of the following patterns are considered errors:
8+
:thumbsdown: Any use of the following patterns are considered errors:
99

1010
```js
1111
expect(element(by.id("myid")).getInnerHtml()).toEqual("test");
@@ -16,7 +16,7 @@ $$(".class").first().getOuterHtml();
1616
$(".class").getInnerHtml().then(function (html) { console.log(html) });
1717
```
1818

19-
The following patterns are not warnings:
19+
:thumbsup: The following patterns are not warnings:
2020

2121
```js
2222
expect(element(by.id("myid")).getText()).toEqual("test");

docs/rules/no-get-raw-id.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Use `getId()` method instead.
55

66
## Rule details
77

8-
Any use of the following patterns are considered errors:
8+
:thumbsdown: Any use of the following patterns are considered errors:
99

1010
```js
1111
expect(element(by.id("myid")).getRawId()).toEqual("id");
@@ -15,7 +15,7 @@ $$(".class").first().getRawId();
1515
$(".class").getRawId().then(function (id) { console.log(id) });
1616
```
1717

18-
The following patterns are not warnings:
18+
:thumbsup: The following patterns are not warnings:
1919

2020
```js
2121
expect(element(by.id("myid")).getId()).toEqual("id");

docs/rules/no-invalid-selectors.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ This rule works great when ESLint is tied up to your editor of choice to make ch
88

99
This rule is almost entirely based on [`css-selector-parser`](https://github.com/mdevils/node-css-selector-parser) parsing abilities.
1010

11-
Any use of the following patterns are considered errors:
11+
:thumbsdown: Any use of the following patterns are considered errors:
1212

1313
```js
1414
element(by.css("["));
@@ -22,7 +22,7 @@ element(by.id("id")).$$("input::first-type");
2222
element(by.id("id")).$("input::first-of--type()");
2323
```
2424

25-
The following patterns are not errors:
25+
:thumbsup: The following patterns are not errors:
2626

2727
```js
2828
element(by.css(".myclass"));

0 commit comments

Comments
 (0)