Permalink
Browse files

Tests: Extend invalid and ignore-option tests

  • Loading branch information...
1 parent a78d009 commit c75700f87a5d360cd939b04bf592defbabfeab00 @jzaefferer committed Mar 11, 2014
Showing with 15 additions and 7 deletions.
  1. +15 −6 test/html_test.js
  2. +0 −1 test/invalid.html
View
@@ -29,30 +29,39 @@ exports.htmllint = {
files: ['test/valid.html', 'test/invalid.html']
}, [
{
- lastLine: 10,
+ lastLine: 1,
+ lastColumn: 16,
+ message: 'Start tag seen without seeing a doctype first. Expected “<!DOCTYPE html>”.',
+ file: 'test/invalid.html'
+ },
+ {
+ lastLine: 9,
lastColumn: 81,
message: 'An “img” element must have an “alt” attribute, except under certain conditions. For details, consult guidance on providing text alternatives for images.',
file: 'test/invalid.html'
},
{
- lastLine: 12,
+ lastLine: 11,
lastColumn: 19,
message: 'The “clear” attribute on the “br” element is obsolete. Use CSS instead.',
file: 'test/invalid.html'
}
- ], 'two errors from test/invalid.html');
+ ], 'three errors from test/invalid.html');
},
'ignore': function(test) {
run(test, {
- ignore: ['The “clear” attribute on the “br” element is obsolete. Use CSS instead.'],
+ ignore: [
+ 'The “clear” attribute on the “br” element is obsolete. Use CSS instead.',
+ 'Start tag seen without seeing a doctype first. Expected “<!DOCTYPE html>”.'
+ ],
files: ['test/valid.html', 'test/invalid.html']
}, [
{
- lastLine: 10,
+ lastLine: 9,
lastColumn: 81,
message: 'An “img” element must have an “alt” attribute, except under certain conditions. For details, consult guidance on providing text alternatives for images.',
file: 'test/invalid.html'
}
- ], 'one error from test/invalid.html, other one was ignored');
+ ], 'one error from test/invalid.html, other two were ignored');
}
};
View
@@ -1,4 +1,3 @@
-<!DOCTYPE html>
<html lang="en">
<head>
<title>jQuery UI Autocomplete - Custom data and display</title>

0 comments on commit c75700f

Please sign in to comment.