Manipulation: support data-URI scripts insertion

Ref 15f4dec789
This commit is contained in:
Bin Xin
2014-11-28 14:09:29 +08:00
committed by Oleg Gaidarenko
parent fa70df692e
commit bc1902ddc0
2 changed files with 10 additions and 0 deletions

View File

@@ -2461,3 +2461,12 @@ test( "Make sure jQuery.fn.remove can work on elements in documentFragment", 1,
equal( fragment.childNodes.length, 0, "div element was removed from documentFragment" );
});
asyncTest( "Insert script with data-URI (gh-1887)", 1, function() {
Globals.register( "testFoo" );
jQuery( "#qunit-fixture" ).append( "<script src=\"data:text/javascript,testFoo = 'foo';\"></script>" );
setTimeout(function (){
strictEqual( window[ "testFoo" ], "foo", "data-URI script executed" );
start();
}, 100 );
});