Commit 90a4abd5 authored by John Resig's avatar John Resig

Tweaked the name unit tests to specify the exact nodes from which to test against.

parent d48db1f4
...@@ -174,8 +174,8 @@ test("name", function() { ...@@ -174,8 +174,8 @@ test("name", function() {
equals( a.length, 3, "Make sure the right number of elements were inserted." ); equals( a.length, 3, "Make sure the right number of elements were inserted." );
equals( a[1].id, "tName2ID", "Make sure the right number of elements were inserted." ); equals( a[1].id, "tName2ID", "Make sure the right number of elements were inserted." );
t( "Find elements that have similar IDs", "[name=tName1]", ["tName1ID"] ); equals( jQuery("[name=tName1]")[0], a[0], "Find elements that have similar IDs" );
t( "Find elements that have similar IDs", "[name=tName2]", ["tName2ID"] ); equals( jQuery("[name=tName2]")[0], a[1], "Find elements that have similar IDs" );
t( "Find elements that have similar IDs", "#tName2ID", ["tName2ID"] ); t( "Find elements that have similar IDs", "#tName2ID", ["tName2ID"] );
a.remove(); a.remove();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment