Remove deleteExpando detect.

This commit is contained in:
Dave Methvin 2013-01-02 20:53:33 -05:00
parent aa529696fb
commit 11e6a66002
2 changed files with 0 additions and 42 deletions

View File

@ -36,7 +36,6 @@ jQuery.support = (function() {
boxModel: document.compatMode === "CSS1Compat",
// Will be defined later
deleteExpando: true,
noCloneEvent: true,
reliableMarginRight: true,
boxSizingReliable: true,
@ -52,13 +51,6 @@ jQuery.support = (function() {
select.disabled = true;
support.optDisabled = !opt.disabled;
// Support: IE<9
try {
delete div.test;
} catch( e ) {
support.deleteExpando = false;
}
// Check if an input maintains its value after becoming a radio
input = document.createElement("input");
input.value = "t";

View File

@ -99,40 +99,6 @@ test("jQuery.data(document)", 25, function() {
QUnit.expectJqData(document, "foo");
});
test("Expando cleanup", 4, function() {
var expected, actual,
div = document.createElement("div");
function assertExpandoAbsent(message) {
if (jQuery.support.deleteExpando) {
expected = false;
actual = jQuery.expando in div;
} else {
expected = null;
actual = div[ jQuery.expando ];
}
equal( actual, expected, message );
}
assertExpandoAbsent("There is no expando on new elements");
jQuery.data(div, "foo", 100);
jQuery.data(div, "bar", 200);
ok(jQuery.expando in div, "There is an expando on the element after using $.data()");
jQuery.removeData(div, "foo");
ok(jQuery.expando in div, "There is still an expando on the element after removing (some) of the data");
jQuery.removeData(div, "bar");
assertExpandoAbsent("Removing the last item in the data store deletes the expando");
// Clean up unattached element
jQuery(div).remove();
});
test("jQuery.acceptData", function() {
expect(7);