Skip to content

Commit

Permalink
More test help for yeti and yuitest driver
Browse files Browse the repository at this point in the history
  • Loading branch information
davglass committed Sep 24, 2012
1 parent f24daf6 commit 4c15602
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 33 deletions.
26 changes: 15 additions & 11 deletions src/yui/tests/unit/coverage.html
Expand Up @@ -120,18 +120,22 @@

//This is a YUITest hack to rename this test for reporting
Y.Test.Runner.setName('YUI: Coverage');
var timer,
check = function() {
var f = document.getElementById('xframe');
if (f && f.contentWindow && f.contentWindow._xframeLoaded) {
clearInterval(timer);
Y.Test.Runner.run();
return true;
}
return false;
};
if (window && window.$yetify) {
var timer,
check = function() {
var f = document.getElementById('xframe');
if (f && f.contentWindow && f.contentWindow._xframeLoaded) {
clearInterval(timer);
Y.Test.Runner.run();
return true;
}
return false;
};

timer = setInterval(check, 100);
timer = setInterval(check, 100);
} else {
Y.Test.Runner.run();
}
});

</script>
Expand Down
26 changes: 15 additions & 11 deletions src/yui/tests/unit/index-static.html
Expand Up @@ -117,18 +117,22 @@
new Y.Test.Console().render('#log');

Y.Test.Runner.setName(TestName);
var timer,
check = function() {
var f = document.getElementById('xframe');
if (f && f.contentWindow && f.contentWindow._xframeLoaded) {
clearInterval(timer);
Y.Test.Runner.run();
return true;
}
return false;
};
if (window && window.$yetify) {
var timer,
check = function() {
var f = document.getElementById('xframe');
if (f && f.contentWindow && f.contentWindow._xframeLoaded) {
clearInterval(timer);
Y.Test.Runner.run();
return true;
}
return false;
};

timer = setInterval(check, 100);
timer = setInterval(check, 100);
} else {
Y.Test.Runner.run();
}
});

</script>
Expand Down
26 changes: 15 additions & 11 deletions src/yui/tests/unit/lang.html
Expand Up @@ -23,18 +23,22 @@
}).use('lang-test', 'test-console', function (Y) {
new Y.Test.Console().render('#log');

var timer,
check = function() {
var f = document.getElementById('xframe');
if (f && f.contentWindow && f.contentWindow._xframeLoaded) {
clearInterval(timer);
Y.Test.Runner.run();
return true;
}
return false;
};
if (window && window.$yetify) {
var timer,
check = function() {
var f = document.getElementById('xframe');
if (f && f.contentWindow && f.contentWindow._xframeLoaded) {
clearInterval(timer);
Y.Test.Runner.run();
return true;
}
return false;
};

timer = setInterval(check, 100);
timer = setInterval(check, 100);
} else {
Y.Test.Runner.run();
}

});
</script>
Expand Down

0 comments on commit 4c15602

Please sign in to comment.