Skip to content

Commit 9159923

Browse files
committed
Add failing testcase
1 parent 8ae414c commit 9159923

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

tests/a11y-role-supports-aria-props.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,18 @@ function getErrorMessage(attribute, role) {
2929

3030
ruleTester.run('a11y-role-supports-aria-props', rule, {
3131
valid: [
32+
{
33+
code: `
34+
<div
35+
id={id}
36+
role={
37+
sectionHasHeader && rowIndex.row === 0 ? 'presentation' : 'option'
38+
}
39+
aria-label={this.props.ariaLabel}
40+
>
41+
{children}
42+
</div>`,
43+
},
3244
{code: '<Foo bar />'},
3345
{code: '<div />'},
3446
{code: '<div id="main" />'},

0 commit comments

Comments
 (0)