diff options
Diffstat (limited to 'test/unit/data.js')
-rw-r--r-- | test/unit/data.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/unit/data.js b/test/unit/data.js index bf5629644..086067cdc 100644 --- a/test/unit/data.js +++ b/test/unit/data.js @@ -170,6 +170,12 @@ test("jQuery.data(object/flash)", 25, function() { dataTests( flash ); }); +// attempting to access the data of an undefined jQuery element should be undefined +test("jQuery().data() === undefined (#14101)", 2, function() { + strictEqual(jQuery().data(), undefined); + strictEqual(jQuery().data("key"), undefined); +}); + test(".data()", function() { expect(5); |