mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-12-16 22:10:13 +01:00
Update code/tests with latest functionality in Ruby markdownlint.
This commit is contained in:
parent
2d8122a3be
commit
fdeeddc99d
10 changed files with 57 additions and 7 deletions
|
|
@ -1,3 +1,3 @@
|
|||
## A level 2 top level header
|
||||
|
||||
## Another one {MD025}
|
||||
## Another one {MD025}
|
||||
|
|
@ -33,3 +33,8 @@ even though the emphasized text is on its own line.
|
|||
|
||||
This is another **normal** paragraph with some text in it. This also should
|
||||
not trigger the rule.
|
||||
|
||||
**This is an entire paragraph that has been emphasized, and shouldn't be
|
||||
detected as a header because it's on multiple lines**
|
||||
|
||||
**This also shouldn't be detected as a header as it ends in punctuation.**
|
||||
|
|
|
|||
|
|
@ -6,4 +6,7 @@ Some text
|
|||
Some text
|
||||
## Header 4 {MD022}
|
||||
|
||||
## Header 5
|
||||
## Header 5
|
||||
|
||||
* This shouldn't trigger MD022, but did because of some bug where we tried to
|
||||
#catch headers that kramdown didn't parse correctly.
|
||||
|
|
|
|||
|
|
@ -6,4 +6,15 @@ Some text
|
|||
===================================
|
||||
|
||||
Setext style title only indented {MD023}
|
||||
=========================================
|
||||
=========================================
|
||||
|
||||
* Test situations in which MD023 shouldn't be triggered.
|
||||
|
||||
```rb
|
||||
# This shouldn't trigger MD023 as it is a code comment.
|
||||
foo = "And here is some code"
|
||||
```
|
||||
|
||||
* This is another case where MD023 shouldn't be triggered
|
||||
# Test {MD023} Valid header for CommonMark (see section 5.2)
|
||||
# Test {MD023} Also valid header for CommonMark
|
||||
|
|
|
|||
16
test/jekyll_post.md
Normal file
16
test/jekyll_post.md
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
---
|
||||
layout: post
|
||||
title: Hello World!
|
||||
category: Meta
|
||||
tags:
|
||||
- tag
|
||||
- another tag
|
||||
- one more tag
|
||||
url: http://example.com
|
||||
excerpt: Hello World! Vestibulum imperdiet adipiscing arcu, quis aliquam dolor condimentum dapibus. Aliquam fermentum leo aliquet quam volutpat et molestie mauris mattis. Suspendisse semper consequat velit in suscipit.
|
||||
---
|
||||
# header1
|
||||
|
||||
This is just a sample post.
|
||||
|
||||
### offending header3 {MD001}
|
||||
|
|
@ -9,6 +9,13 @@ Here is a short line in a code block.
|
|||
Here is a very very very very very very very very very very very very very very very very very very very long line in a code block.
|
||||
```
|
||||
|
||||
```text
|
||||
test
|
||||
test
|
||||
|
||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut
|
||||
```
|
||||
|
||||
This is a short line.
|
||||
|
||||
| First Header | Second Header | Third Header | Fourth Header | Fifth Header | Sixth Header |
|
||||
|
|
|
|||
|
|
@ -857,7 +857,7 @@ module.exports.readme = function readme(test) {
|
|||
};
|
||||
|
||||
module.exports.doc = function doc(test) {
|
||||
test.expect(292);
|
||||
test.expect(293);
|
||||
fs.readFile("doc/Rules.md", shared.utf8Encoding,
|
||||
function readFile(err, contents) {
|
||||
test.ifError(err);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue