From 72023dd045a7fead5a3136ec2400ad4743a190d2 Mon Sep 17 00:00:00 2001 From: Jörn Zaefferer Date: Tue, 28 Feb 2012 15:56:32 +0100 Subject: Update to QUnit 1.3. Replace usage of same with deepEqual and equals with equal. --- tests/unit/sortable/sortable_methods.js | 18 +++++++++--------- tests/unit/sortable/sortable_tickets.js | 4 ++-- 2 files changed, 11 insertions(+), 11 deletions(-) (limited to 'tests/unit/sortable') diff --git a/tests/unit/sortable/sortable_methods.js b/tests/unit/sortable/sortable_methods.js index c4b5cdc08..2446d2755 100644 --- a/tests/unit/sortable/sortable_methods.js +++ b/tests/unit/sortable/sortable_methods.js @@ -17,7 +17,7 @@ var drag = function(handle, dx, dy) { var sort = function(handle, dx, dy, index, msg) { drag(handle, dx, dy); - equals($(handle).parent().children().index(handle), index, msg); + equal($(handle).parent().children().index(handle), index, msg); } module("sortable: methods"); @@ -59,7 +59,7 @@ test("destroy", function() { var expected = $('
').sortable(), actual = expected.sortable('destroy'); - equals(actual, expected, 'destroy is chainable'); + equal(actual, expected, 'destroy is chainable'); }); test("enable", function() { @@ -69,18 +69,18 @@ test("enable", function() { sort($("li", el)[0], 0, 40, 0, '.sortable({ disabled: true })'); el.sortable("enable"); - equals(el.sortable("option", "disabled"), false, "disabled option getter"); + equal(el.sortable("option", "disabled"), false, "disabled option getter"); el.sortable("destroy"); el.sortable({ disabled: true }); el.sortable("option", "disabled", false); - equals(el.sortable("option", "disabled"), false, "disabled option setter"); + equal(el.sortable("option", "disabled"), false, "disabled option setter"); sort($("li", el)[0], 0, 40, 2, '.sortable("option", "disabled", false)'); - + var expected = $('
').sortable(), actual = expected.sortable('enable'); - equals(actual, expected, 'enable is chainable'); + equal(actual, expected, 'enable is chainable'); }); test("disable", function() { @@ -96,13 +96,13 @@ test("disable", function() { el.sortable({ disabled: false }); sort($("li", el)[0], 0, 40, 2, '.sortable({ disabled: false })'); el.sortable("option", "disabled", true); - equals(el.sortable("option", "disabled"), true, "disabled option setter"); + equal(el.sortable("option", "disabled"), true, "disabled option setter"); ok(el.sortable("widget").is(":not(.ui-state-disabled)"), "sortable element does not get ui-state-disabled since it's an interaction"); sort($("li", el)[0], 0, 40, 0, '.sortable("option", "disabled", true)'); - + var expected = $('
').sortable(), actual = expected.sortable('disable'); - equals(actual, expected, 'disable is chainable'); + equal(actual, expected, 'disable is chainable'); }); })(jQuery); diff --git a/tests/unit/sortable/sortable_tickets.js b/tests/unit/sortable/sortable_tickets.js index 3edc8c04c..6ee503a58 100644 --- a/tests/unit/sortable/sortable_tickets.js +++ b/tests/unit/sortable/sortable_tickets.js @@ -17,7 +17,7 @@ var drag = function(handle, dx, dy) { var sort = function(handle, dx, dy, index, msg) { drag(handle, dx, dy); - equals($(handle).parent().children().index(handle), index, msg); + equal($(handle).parent().children().index(handle), index, msg); } module("sortable: tickets"); @@ -32,7 +32,7 @@ test("#3019: Stop fires too early", function() { }); sort($("li", el)[0], 0, 40, 2, 'Dragging the sortable'); - equals(helper, null, "helper should be false"); + equal(helper, null, "helper should be false"); }); -- cgit v1.2.3