aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/button
diff options
context:
space:
mode:
authorScott González <scott.gonzalez@gmail.com>2012-04-20 11:06:11 -0400
committerScott González <scott.gonzalez@gmail.com>2012-04-20 11:06:11 -0400
commit308b55e50ca781ad9db08a252f313ee2e8e2f257 (patch)
treeb287b6936d45efdfe067d2bdf4c732b13a1726bd /tests/unit/button
parent2cf9948cadf45a24c591d6f7232f2470b4d9743e (diff)
parent33df9b788d3f60459c43acbfefdfeef8a07ce632 (diff)
downloadjquery-ui-308b55e50ca781ad9db08a252f313ee2e8e2f257.tar.gz
jquery-ui-308b55e50ca781ad9db08a252f313ee2e8e2f257.zip
Merge branch 'master' into position-notification
Diffstat (limited to 'tests/unit/button')
-rw-r--r--tests/unit/button/button_core.js11
-rw-r--r--tests/unit/button/button_defaults.js2
-rw-r--r--tests/unit/button/button_methods.js4
3 files changed, 9 insertions, 8 deletions
diff --git a/tests/unit/button/button_core.js b/tests/unit/button/button_core.js
index c110b4311..0d93ecedf 100644
--- a/tests/unit/button/button_core.js
+++ b/tests/unit/button/button_core.js
@@ -8,7 +8,7 @@
module("button: core");
test("checkbox", function() {
- var input = $("#check");
+ var input = $("#check"),
label = $("label[for=check]");
ok( input.is(":visible") );
ok( label.is(":not(.ui-button)") );
@@ -18,7 +18,7 @@ test("checkbox", function() {
});
test("radios", function() {
- var inputs = $("#radio0 input");
+ var inputs = $("#radio0 input"),
labels = $("#radio0 label");
ok( inputs.is(":visible") );
ok( labels.is(":not(.ui-button)") );
@@ -51,7 +51,7 @@ test("radio groups", function() {
});
test("input type submit, don't create child elements", function() {
- var input = $("#submit")
+ var input = $("#submit");
deepEqual( input.children().length, 0 );
input.button();
deepEqual( input.children().length, 0 );
@@ -68,11 +68,12 @@ test("buttonset", function() {
});
test("buttonset (rtl)", function() {
- var parent = $("#radio1").parent();
+ var set,
+ parent = $("#radio1").parent();
// Set to rtl
parent.attr("dir", "rtl");
- var set = $("#radio1").buttonset();
+ set = $("#radio1").buttonset();
ok( set.is(".ui-buttonset") );
deepEqual( set.children(".ui-button").length, 3 );
deepEqual( set.children("input:radio.ui-helper-hidden-accessible").length, 3 );
diff --git a/tests/unit/button/button_defaults.js b/tests/unit/button/button_defaults.js
index 96c7e5bfa..ef22d3011 100644
--- a/tests/unit/button/button_defaults.js
+++ b/tests/unit/button/button_defaults.js
@@ -1,4 +1,4 @@
-commonWidgetTests( "button", {
+TestHelpers.commonWidgetTests( "button", {
defaults: {
disabled: null,
icons: {
diff --git a/tests/unit/button/button_methods.js b/tests/unit/button/button_methods.js
index a83a73ba4..347806d4e 100644
--- a/tests/unit/button/button_methods.js
+++ b/tests/unit/button/button_methods.js
@@ -7,8 +7,8 @@
module("button: methods");
test("destroy", function() {
- var beforeHtml = $("#button").parent().html();
- var afterHtml = $("#button").button().button("destroy").parent().html();
+ var beforeHtml = $("#button").parent().html(),
+ afterHtml = $("#button").button().button("destroy").parent().html();
// Opera 9 outputs role="" instead of removing the attribute like everyone else
if ($.browser.opera) {
afterHtml = afterHtml.replace(/ role=""/g, "");