Tests: Keep iframes visible in TestSwarm

Ref 1d2df772b4
This commit is contained in:
Richard Gibson 2017-04-28 23:54:06 -04:00
parent dd408ce12f
commit c0edd8dc18

View File

@ -238,8 +238,19 @@ this.testIframe = function( title, fileName, func, wrapper ) {
wrapper.call( QUnit, title, function( assert ) { wrapper.call( QUnit, title, function( assert ) {
var done = assert.async(), var done = assert.async(),
$iframe = supportjQuery( "<iframe/>" ) $iframe = supportjQuery( "<iframe/>" )
.css( { position: "absolute", width: "500px", left: "-600px" } ) .attr( { id: "qunit-fixture-iframe", src: url( "./data/" + fileName ) } )
.attr( { id: "qunit-fixture-iframe", src: url( "./data/" + fileName ) } ); .css( {
position: "absolute",
top: "0",
left: "-600px",
height: "300px",
width: "500px"
} );
// Overcome TestSwarm iframe visibilty quirks
if ( QUnit.isSwarm ) {
$iframe.css( { left: "0" } );
}
// Test iframes are expected to invoke this via startIframeTest (cf. iframeTest.js) // Test iframes are expected to invoke this via startIframeTest (cf. iframeTest.js)
window.iframeCallback = function() { window.iframeCallback = function() {