Commit a1f10357 by Greg Look

Wait for all panels to render in PhantomJS.

parent 8eb3e48b
...@@ -36,7 +36,8 @@ page.open(params.url, function (status) { ...@@ -36,7 +36,8 @@ page.open(params.url, function (status) {
var canvas = page.evaluate(function() { var canvas = page.evaluate(function() {
var body = angular.element(document.body); // 1 var body = angular.element(document.body); // 1
var rootScope = body.scope().$root; var rootScope = body.scope().$root;
return rootScope.performance.panelsRendered > 0; var panels = angular.element('div.panel').length;
return rootScope.performance.panelsRendered >= panels;
}); });
if (canvas || tries === 1000) { if (canvas || tries === 1000) {
......
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