diff options
-rw-r--r-- | tests/unit/slider/slider_events.js | 24 |
1 files changed, 23 insertions, 1 deletions
diff --git a/tests/unit/slider/slider_events.js b/tests/unit/slider/slider_events.js index a3d6c5282..dd68a74b6 100644 --- a/tests/unit/slider/slider_events.js +++ b/tests/unit/slider/slider_events.js @@ -20,7 +20,7 @@ test( "slide", function() { // value (even if same as previous value), via mouse(mouseup) or keyboard(keyup) // or value method/option" test( "change", function() { - expect(4); + expect(7); var handle; // Test mouseup at end of handle slide (mouse) @@ -61,6 +61,17 @@ test( "change", function() { .slider( "value", 0 ); reset(); + // Test values method + el = $( "<div></div>" ) + .slider({ + values: [ 10, 20 ], + change: function(event, ui) { + ok( true, "change triggered by values method" ); + } + }) + .slider( "values", [80, 90] ); + + reset(); // Test value option el = $( "<div></div>" ) .slider({ @@ -70,6 +81,17 @@ test( "change", function() { }) .slider( "option", "value", 0 ); + reset(); + // Test values option + el = $( "<div></div>" ) + .slider({ + values: [ 10, 20 ], + change: function(event, ui) { + ok( true, "change triggered by values option" ); + } + }) + .slider( "option", "values", [80, 90] ); + }); test( "stop", function() { |