Skip to content

Commit

Permalink
Add message url
Browse files Browse the repository at this point in the history
Closes GH-117.

Reviewed-by: Titus Wormer <[email protected]>
  • Loading branch information
remcohaszing authored Dec 19, 2021
1 parent 935e7f4 commit acdfb8f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion lib/factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ import {convert} from 'unist-util-is'

const own = {}.hasOwnProperty

const url = 'https://github.com/retextjs/retext-equality#readme'

const word = convert('WordNode')
const whiteSpace = convert('WhiteSpaceNode')
const punctuation = convert('PunctuationNode')
Expand Down Expand Up @@ -256,7 +258,7 @@ export function factory(patterns, lang) {
match.nodes[0],
[source, pattern.id].join(':')
),
{actual, expected, note: pattern.note}
{actual, expected, note: pattern.note, url}
)
}
}
3 changes: 2 additions & 1 deletion test.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ test('retext-equality', (t) => {
'person with a disability',
'people with disabilities'
],
note: 'Assumes/implies that a person with a disability is deficient or inferior to others. When possible, specify the functional ability or its restriction. (source: https://ncdj.org/style-guide/)'
note: 'Assumes/implies that a person with a disability is deficient or inferior to others. When possible, specify the functional ability or its restriction. (source: https://ncdj.org/style-guide/)',
url: 'https://github.com/retextjs/retext-equality#readme'
},
'should emit a message'
)
Expand Down

0 comments on commit acdfb8f

Please sign in to comment.