aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit/ajax.js
diff options
context:
space:
mode:
authorgnarf <gnarf@gnarf.net>2011-02-24 13:21:05 -0600
committergnarf <gnarf@gnarf.net>2011-02-24 13:21:05 -0600
commit71bd828d9f975fb1047b9fa2a78949cafd8006ac (patch)
tree22acf186e06ab3cdab28bb9913ec1169f0f2d164 /test/unit/ajax.js
parent14e9da51f96a7a9b1a5c239c32f4abe20eb2b795 (diff)
downloadjquery-71bd828d9f975fb1047b9fa2a78949cafd8006ac.tar.gz
jquery-71bd828d9f975fb1047b9fa2a78949cafd8006ac.zip
Grouped up the test
Diffstat (limited to 'test/unit/ajax.js')
-rw-r--r--test/unit/ajax.js22
1 files changed, 9 insertions, 13 deletions
diff --git a/test/unit/ajax.js b/test/unit/ajax.js
index 4ce15f8f3..2a2ac46a1 100644
--- a/test/unit/ajax.js
+++ b/test/unit/ajax.js
@@ -492,7 +492,7 @@ test(".ajax() - hash", function() {
test("jQuery ajax - cross-domain detection", function() {
- expect( 4 );
+ expect( 5 );
var loc = document.location,
otherPort = loc.port === 666 ? 667 : 666,
@@ -508,6 +508,14 @@ test("jQuery ajax - cross-domain detection", function() {
});
jQuery.ajax({
+ url: 'app:/path',
+ beforeSend: function( _ , s ) {
+ ok( s.crossDomain , "Adobe AIR app:/ URL detected as cross-domain" );
+ return false;
+ }
+ });
+
+ jQuery.ajax({
dataType: "jsonp",
url: loc.protocol + '//somewebsitethatdoesnotexist-656329477541.com:' + ( loc.port || 80 ),
beforeSend: function( _ , s ) {
@@ -2239,18 +2247,6 @@ test("jQuery.ajax - active counter", function() {
ok( jQuery.active == 0, "ajax active counter should be zero: " + jQuery.active );
});
-test("jQuery.ajax - compatible with AIR urls"), function() {
- expect( 1 );
- stop();
- $.ajax({
- url: "app:/testing",
- beforeSend: function() {
- ok( this.crossDomain, "Detected crossDomain for AIR Url" );
- return false;
- }
- });
-});
-
}
//} \ No newline at end of file