Fix #11586. Ajax DELETE ain't got no body, so data goes to its URL.

This commit is contained in:
Dave Methvin
2012-08-23 21:30:45 -04:00
parent a9c2a9bf61
commit c01e022f33
2 changed files with 16 additions and 1 deletions

View File

@@ -840,6 +840,21 @@ test("jQuery.ajax - HEAD requests", function() {
});
test("jQuery.ajax - DELETE requests", function() {
expect(1);
jQuery.ajax({
url: "devo.html",
type: "DELETE",
data: { "whip": "it", "qty": "good" },
beforeSend: function( _ , s ) {
equal( s.url, "devo.html?whip=it&qty=good", "Delete requests encode data in URL" );
return false;
}
});
});
test("jQuery.ajax - beforeSend", function() {
expect(1);
stop();