Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Added test for next/prev

  • Loading branch information...
commit 694becea3898f060ed815cf864ea1d4e87a800fb 1 parent ea283bd
Jörn Zaefferer jzaefferer authored

Showing 1 changed file with 10 additions and 0 deletions. Show diff stats Hide diff stats

  1. +10 0 src/jquery/coreTest.js
10 src/jquery/coreTest.js
@@ -398,6 +398,16 @@ test("parent[s]([String])", function() {
398 398 ok( $("#groups").parents("div")[0].id == "main", "Filtered parents check2" );
399 399 });
400 400
  401 +test("next/prev([String])", function() {
  402 + ok( $("#ap").next()[0].id == "foo", "Simple next check" );
  403 + ok( $("#ap").next("div")[0].id == "foo", "Filtered next check" );
  404 + ok( $("#ap").next("p").length == 0, "Filtered next check, no match" );
  405 +
  406 + ok( $("#foo").prev()[0].id == "ap", "Simple prev check" );
  407 + ok( $("#foo").prev("p")[0].id == "ap", "Filtered prev check" );
  408 + ok( $("#foo").prev("div").length == 0, "Filtered prev check, no match" );
  409 +});
  410 +
401 411 test("show()", function() {
402 412 expect(1);
403 413 var pass = true, div = $("div");

0 comments on commit 694bece

Please sign in to comment.
Something went wrong with that request. Please try again.