Skip to content
Permalink
Browse files

Make test render checker work correctly in non-Firefox browsers

  • Loading branch information
nyalldawson committed Jan 6, 2016
1 parent f5b615a commit 0afcb0f3649042bb738858b53cea63dece6658f8
Showing with 5 additions and 2 deletions.
  1. +5 −2 tests/renderchecker.js
@@ -2,11 +2,13 @@ function addComparison(id,rendered,expected,w,h) {
var e = document.getElementById(id);

var div = document.createElement("DIV");
div.style = "margin: 0 auto; font-size: 0;";
div.style.margin = "0 auto";
div.style.fontSize = "0";
e.appendChild(div);

var div0 = document.createElement("DIV");
div0.style = "font-size: 0; position: relative;";
div0.style.fontSize = "0";
div0.style.position = "relative";
div.appendChild(div0);

var img = document.createElement("IMG");
@@ -17,6 +19,7 @@ function addComparison(id,rendered,expected,w,h) {
div0.appendChild(img);

var div1 = document.createElement("DIV");
div1.setAttribute("style", "pointer-events: none");
div1.style.backgroundImage = "url('" + expected + "')";
div1.style.backgroundSize = "cover";
div1.style.position = "absolute";

0 comments on commit 0afcb0f

Please sign in to comment.
You can’t perform that action at this time.