mirror of
https://github.com/jquery/jquery.git
synced 2026-04-20 03:01:22 -04:00
A fix for bug #1443, where globalEval occurred asynchronously in Safari 2, provided by Andrea Giammarchi.
This commit is contained in:
@@ -123,11 +123,18 @@ test("isFunction", function() {
|
||||
});
|
||||
});
|
||||
|
||||
var foo = false;
|
||||
|
||||
test("$('html')", function() {
|
||||
expect(2);
|
||||
expect(4);
|
||||
|
||||
reset();
|
||||
ok( $("<script>var foo='test';</script>")[0], "Creating a script" );
|
||||
foo = false;
|
||||
var s = $("<script>var foo='test';</script>")[0];
|
||||
ok( s, "Creating a script" );
|
||||
ok( !foo, "Make sure the script wasn't executed prematurely" );
|
||||
$("body").append(s);
|
||||
ok( foo, "Executing a scripts contents in the right context" );
|
||||
|
||||
reset();
|
||||
ok( $("<link rel='stylesheet'/>")[0], "Creating a link" );
|
||||
|
||||
Reference in New Issue
Block a user