diff options
author | Laurent Arnoud <laurent@spkdev.net> | 2017-02-23 21:57:01 +0100 |
---|---|---|
committer | Laurent Arnoud <laurent@spkdev.net> | 2017-02-23 21:57:01 +0100 |
commit | d150ef00c5f0d2f132dce503b68c467ce825a54f (patch) | |
tree | d2b4ca1aaa8801457931124929f84758df556330 /guides | |
parent | 71df60e921a784fb01729e98fa9636a4b6862d72 (diff) | |
download | rails-d150ef00c5f0d2f132dce503b68c467ce825a54f.tar.gz rails-d150ef00c5f0d2f132dce503b68c467ce825a54f.tar.bz2 rails-d150ef00c5f0d2f132dce503b68c467ce825a54f.zip |
Fix w3c_validator.rb validation script
Diffstat (limited to 'guides')
-rw-r--r-- | guides/w3c_validator.rb | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/guides/w3c_validator.rb b/guides/w3c_validator.rb index c0a32c6b91..4671e040ca 100644 --- a/guides/w3c_validator.rb +++ b/guides/w3c_validator.rb @@ -32,7 +32,8 @@ include W3CValidators module RailsGuides class Validator def validate - validator = MarkupValidator.new + # https://github.com/w3c-validators/w3c_validators/issues/25 + validator = NuValidator.new STDOUT.sync = true errors_on_guides = {} @@ -44,11 +45,11 @@ module RailsGuides next end - if results.validity - print "." - else + if results.errors.length > 0 print "E" errors_on_guides[f] = results.errors + else + print "." end end |