From e93ca40aa7ec4337a57fcdbc699d900e01b4c67e Mon Sep 17 00:00:00 2001 From: timmywil Date: Fri, 25 Mar 2011 23:52:36 -0400 Subject: [PATCH] Bug #7369: Check non-existent attribute as well to be sure --- test/unit/traversing.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/unit/traversing.js b/test/unit/traversing.js index f5cd8aac..43a9f22a 100644 --- a/test/unit/traversing.js +++ b/test/unit/traversing.js @@ -148,7 +148,7 @@ test("filter(jQuery)", function() { }) test("closest()", function() { - expect(12); + expect(13); same( jQuery("body").closest("body").get(), q("body"), "closest(body)" ); same( jQuery("body").closest("html").get(), q("html"), "closest(html)" ); same( jQuery("body").closest("div").get(), [], "closest(div)" ); @@ -170,6 +170,7 @@ test("closest()", function() { equals( jQuery("

").find("p").closest("table").length, 0, "Make sure disconnected closest work." ); // Bug #7369 equals( jQuery('
').closest('[foo]').length, 1, "Disconnected nodes with attribute selector" ); + equals( jQuery('
').closest('[lang]').length, 0, "Disconnected nodes with non-existent attribute selector" ); }); test("closest(Array)", function() {