Browse Source

Output successful URLs even if some fail

renovate/configure
Yota Toyama 8 years ago
parent
commit
90fdb1bad4
  1. 11
      examples/markdown.feature
  2. 2
      url_checker.go

11
examples/markdown.feature

@ -57,3 +57,14 @@ Feature: Markdown
"""
When I successfully run `linkcheck --verbose foo.md`
Then the stderr should contain "OK"
Scenario: Check a markdown file which contains live and dead links in verbose mode
Given a file named "foo.md" with:
"""
[Google](https://google.com)
[The answer](https://some-say-the-answer-is-42.com)
"""
When I run `linkcheck -v foo.md`
Then the exit status should be 1
And the stderr should contain "OK"
And the stderr should contain "ERROR"

2
url_checker.go

@ -41,7 +41,7 @@ func (c urlChecker) CheckMany(ss []string) bool {
ok := true
for i := 0; i < len(ss); i++ {
ok = ok && <-bs
ok = <-bs && ok
}
return ok

Loading…
Cancel
Save