Skip to content

Commit

Permalink
1.2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
optimalisatie committed Sep 26, 2020
1 parent 3e29be4 commit 6139cac
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions test/specs/test-definitions.js
Original file line number Diff line number Diff line change
Expand Up @@ -626,11 +626,16 @@ TEST_DEFINITIONS.basic = function() {
(document.getElementById('img_' + pos).getAttribute('src').indexOf(type) !== -1)
}

setTimeout(function() {

let c = 0;
let i = setInterval(function() {
c++;
if (!check('no_webp', '.png')) {
cb('top img not loaded - src:' + document.getElementById('img_no_webp').getAttribute('src') + ' webp:' + check('no_webp'));
if (c > 10) {
clearInterval(i);
cb('top img not loaded - src:' + document.getElementById('img_no_webp').getAttribute('src') + ' webp:' + check('no_webp'));
}
} else {
clearInterval(i);
cb(true);
}
}, 100);
Expand Down

0 comments on commit 6139cac

Please sign in to comment.