@@ -21,36 +21,37 @@ ruleTester.run('get-attribute', rule, {
21
21
invalid : [
22
22
{
23
23
code : "el.getAttribute('SRC')" ,
24
+ output : "el.getAttribute('src')" ,
24
25
errors : [
25
26
{
26
27
message : 'Attributes should be lowercase and hyphen separated, or part of the SVG whitelist.' ,
27
28
type : 'Literal'
28
29
}
29
- ] ,
30
- output : "el.getAttribute('src')"
30
+ ]
31
31
} ,
32
32
{
33
33
code : "el.hasAttribute('SRC')" ,
34
+ output : "el.hasAttribute('src')" ,
34
35
errors : [
35
36
{
36
37
message : 'Attributes should be lowercase and hyphen separated, or part of the SVG whitelist.' ,
37
38
type : 'Literal'
38
39
}
39
- ] ,
40
- output : "el.hasAttribute('src')"
40
+ ]
41
41
} ,
42
42
{
43
43
code : "el.getAttribute('onClick')" ,
44
+ output : "el.getAttribute('onclick')" ,
44
45
errors : [
45
46
{
46
47
message : 'Attributes should be lowercase and hyphen separated, or part of the SVG whitelist.' ,
47
48
type : 'Literal'
48
49
}
49
- ] ,
50
- output : "el.getAttribute('onclick')"
50
+ ]
51
51
} ,
52
52
{
53
53
code : "el.getAttribute('viewbox')" ,
54
+ output : null ,
54
55
errors : [
55
56
{
56
57
message : 'Attributes should be lowercase and hyphen separated, or part of the SVG whitelist.' ,
@@ -60,6 +61,7 @@ ruleTester.run('get-attribute', rule, {
60
61
} ,
61
62
{
62
63
code : "el.getAttribute('preserveaspectratio')" ,
64
+ output : null ,
63
65
errors : [
64
66
{
65
67
message : 'Attributes should be lowercase and hyphen separated, or part of the SVG whitelist.' ,
0 commit comments