Fixed issue with space separated rel attributes
Conflicts: lib/checks/check-pagination.js lib/checks/check-preload.js
This commit is contained in:
Коммит
21d71c82c4
|
@ -20,8 +20,8 @@
|
|||
var bluebird = require('bluebird');
|
||||
|
||||
var check = bluebird.method(function (website) {
|
||||
var next = website.$('link[rel="next"]'),
|
||||
prev = website.$('link[rel="prev"]'),
|
||||
var next = website.$('link[rel~="next"]'),
|
||||
prev = website.$('link[rel~="prev"]'),
|
||||
test = {
|
||||
testName: 'pagination',
|
||||
passed: false,
|
||||
|
|
|
@ -21,9 +21,9 @@
|
|||
var bluebird = require('bluebird');
|
||||
|
||||
var check = bluebird.method(function (website) {
|
||||
var prefetch = website.$('link[rel="prefetch"]'),
|
||||
dnsPrerender = website.$('link[rel="dns-prefetch"]'),
|
||||
prerender = website.$('link[rel="prerender"]'),
|
||||
var prefetch = website.$('link[rel~="prefetch"]'),
|
||||
dnsPrerender = website.$('link[rel~="dns-prefetch"]'),
|
||||
prerender = website.$('link[rel~="prerender"]'),
|
||||
test = {
|
||||
testName: 'prefetch',
|
||||
passed: false,
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Pagination</title>
|
||||
<meta name="description" content="Pagination next with prefetch">
|
||||
<link rel="next prefetch" href="next.html">
|
||||
</head>
|
||||
<body>
|
||||
<h1>Pagination next with prefetch</h1>
|
||||
<p>Expected result: <b>passes</b></p>
|
||||
</body>
|
||||
</html>
|
|
@ -69,5 +69,8 @@ module.exports['Pagination'] = {
|
|||
}),
|
||||
'Pagination - Prev/Next': checkPage('4.html', {
|
||||
passed: true
|
||||
}),
|
||||
'Pagination - Next with prefetch': checkPage('5.html', {
|
||||
passed: true
|
||||
})
|
||||
};
|
Загрузка…
Ссылка в новой задаче