[chore] add test for no-nointeractive-tabindex

pull/6693/head
shinyaigeek 5 years ago committed by tanhauhau
parent 32eb1bccf4
commit ccb59d91cd

@ -0,0 +1,14 @@
<!-- valid -->
<button />
<button tabindex='0' />
<button tabindex='{0}' />
<div />
<div tabindex='-1' />
<div role='button' tabindex='0' />
<div role='article' tabindex='-1' />
<article tabindex='-1' />
<!-- invalid -->
<div tabindex='0' />
<div role='article' tabindex='0' />
<article tabindex='0' />
<article tabindex='{0}' />

@ -0,0 +1,62 @@
[
{
"code": "a11y-no-nointeractive-tabindex",
"end": {
"character": 241,
"column": 20,
"line": 11
},
"message": "A11y: not interactive element cannot have positive tabIndex value",
"pos": 221,
"start": {
"character": 221,
"column": 0,
"line": 11
}
},
{
"code": "a11y-no-nointeractive-tabindex",
"end": {
"character": 277,
"column": 35,
"line": 12
},
"message": "A11y: not interactive element cannot have positive tabIndex value",
"pos": 242,
"start": {
"character": 242,
"column": 0,
"line": 12
}
},
{
"code": "a11y-no-nointeractive-tabindex",
"end": {
"character": 302,
"column": 24,
"line": 13
},
"message": "A11y: not interactive element cannot have positive tabIndex value",
"pos": 278,
"start": {
"character": 278,
"column": 0,
"line": 13
}
},
{
"code": "a11y-no-nointeractive-tabindex",
"end": {
"character": 329,
"column": 26,
"line": 14
},
"message": "A11y: not interactive element cannot have positive tabIndex value",
"pos": 303,
"start": {
"character": 303,
"column": 0,
"line": 14
}
}
]
Loading…
Cancel
Save