From 32b066d3805a48f8c8312562ed52a1b5910b1d85 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Micha=C5=82=20Go=C5=82e=CC=A8biowski?= Date: Sun, 24 Mar 2013 04:01:50 +0100 Subject: [PATCH] Fix #13655. Add test for jQuery.ready.promise fallback load. Close gh-1209. --- test/data/core/dont_return.php | 3 +++ test/data/core/dynamic_ready.html | 35 +++++++++++++++++++++++++++++++ test/unit/core.js | 5 +++++ 3 files changed, 43 insertions(+) create mode 100644 test/data/core/dont_return.php create mode 100644 test/data/core/dynamic_ready.html diff --git a/test/data/core/dont_return.php b/test/data/core/dont_return.php new file mode 100644 index 000000000..3ac56e1ef --- /dev/null +++ b/test/data/core/dont_return.php @@ -0,0 +1,3 @@ + diff --git a/test/data/core/dynamic_ready.html b/test/data/core/dynamic_ready.html new file mode 100644 index 000000000..799145b98 --- /dev/null +++ b/test/data/core/dynamic_ready.html @@ -0,0 +1,35 @@ + + + + + + + + + + + + diff --git a/test/unit/core.js b/test/unit/core.js index 6cdd3b93d..b54438753 100644 --- a/test/unit/core.js +++ b/test/unit/core.js @@ -24,6 +24,11 @@ testIframeWithCallback( "Conditional compilation compatibility (#13274)", "core/ ok( $(), "jQuery executes" ); }); +testIframeWithCallback( "document ready when jQuery loaded asynchronously (#13655)", "core/dynamic_ready.html", function( ready ) { + expect( 1 ); + equal( true, ready, "document ready correctly fired when jQuery is loaded after DOMContentLoaded" ); +}); + test("jQuery()", function() { var elem, i, -- 2.39.5