Commit 64f19d3c authored by Jérome Perrin's avatar Jérome Perrin

ui_test_core: add waitForFontsLoaded command

parent b1807db1
...@@ -324,3 +324,12 @@ Selenium.prototype.doVerifyImageMatchSnapshot = ( ...@@ -324,3 +324,12 @@ Selenium.prototype.doVerifyImageMatchSnapshot = (
})); }));
}; };
/**
* Wait for fonts to be loaded.
*
* This is useful before checking snapshot
*/
Selenium.prototype.doWaitForFontsLoaded = function() {
return wrapPromise(this.page().getDocument().fonts.ready);
}
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment