Skip to content

Commit

Permalink
Add case insensitive tests
Browse files Browse the repository at this point in the history
  • Loading branch information
khiga8 committed Oct 5, 2023
1 parent 27adc41 commit 95e5135
Show file tree
Hide file tree
Showing 3 changed files with 60 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/no-alt-text.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,11 @@ Multi-line image tag with alt attribute not set
alt
src="image.png"> {MD045:48} {MD033:48}

Uppercase image tag with alt attribute set
<IMG SRC="cat.png" ALT="Descriptive text"> {MD033}

Uppercase image tag with no alt set
<IMG SRC="cat.png">{MD045} {MD033}

[notitle]: image.jpg
[title]: image.jpg "Title"
54 changes: 54 additions & 0 deletions test/snapshots/markdownlint-test-scenarios.js.md
Original file line number Diff line number Diff line change
Expand Up @@ -33803,6 +33803,38 @@ Generated by [AVA](https://avajs.dev).
'no-inline-html',
],
},
{
errorContext: null,
errorDetail: 'Element: IMG',
errorRange: [
1,
42,
],
fixInfo: null,
lineNumber: 53,
ruleDescription: 'Inline HTML',
ruleInformation: 'https://github.com/DavidAnson/markdownlint/blob/v0.0.0/doc/md033.md',
ruleNames: [
'MD033',
'no-inline-html',
],
},
{
errorContext: null,
errorDetail: 'Element: IMG',
errorRange: [
1,
19,
],
fixInfo: null,
lineNumber: 56,
ruleDescription: 'Inline HTML',
ruleInformation: 'https://github.com/DavidAnson/markdownlint/blob/v0.0.0/doc/md033.md',
ruleNames: [
'MD033',
'no-inline-html',
],
},
{
errorContext: null,
errorDetail: null,
Expand Down Expand Up @@ -33976,6 +34008,22 @@ Generated by [AVA](https://avajs.dev).
'no-alt-text',
],
},
{
errorContext: null,
errorDetail: 'Element: IMG',
errorRange: [
1,
19,
],
fixInfo: null,
lineNumber: 56,
ruleDescription: 'Images should have alternate text (alt text)',
ruleInformation: 'https://github.com/DavidAnson/markdownlint/blob/v0.0.0/doc/md045.md',
ruleNames: [
'MD045',
'no-alt-text',
],
},
],
fixed: `# Images with and without alternate text␊
Expand Down Expand Up @@ -34028,6 +34076,12 @@ Generated by [AVA](https://avajs.dev).
alt␊
src="image.png"> {MD045:48} {MD033:48}␊
Uppercase image tag with alt attribute set␊
<IMG SRC="cat.png" ALT="Descriptive text"> {MD033}␊
Uppercase image tag with no alt set␊
<IMG SRC="cat.png">{MD045} {MD033}␊
[notitle]: image.jpg␊
[title]: image.jpg "Title"␊
`,
Expand Down
Binary file modified test/snapshots/markdownlint-test-scenarios.js.snap
Binary file not shown.

0 comments on commit 95e5135

Please sign in to comment.