github
Advanced Search
  • Home
  • Pricing and Signup
  • Explore GitHub
  • Blog
  • Login

jquery / jquery-ui

  • Admin
  • Watch Unwatch
  • Fork
  • Your Fork
  • Pull Request
  • Download Source
    • 263
    • 30
  • Source
  • Commits
  • Network (30)
  • Graphs
  • Tree: e84a318

click here to add a description

click here to add a homepage

  • Switch Branches (4)
    • bind
    • master
    • panel
    • tooltip
  • Switch Tags (15)
    • 1.8rc3
    • 1.8rc2
    • 1.8rc1
    • 1.8b1
    • 1.8a2
    • 1.8a1
    • 1.8
    • 1.7
    • 1.6rc6
    • 1.6rc5
    • 1.6rc3
    • 1.6rc2
    • 1.6
    • 1.5.2
    • 1.5.1
  • Comments
Sending Request…

The official jQuery user interface library. — Read more

  Cancel

http://jqueryui.com/

  Cancel
  • Private
  • Read-Only
  • HTTP Read-Only

This URL has Read+Write access

Slider unit tests: slider event change
rdworth (author)
Wed Mar 17 08:58:22 -0700 2010
commit  e84a318e4670bed0d8690b0a7625df31d39aaf92
tree    be6b1e6bf9487d1e5687275d354590336db8b714
parent  8b885b3d527a64db4317ef1d00e0cc87e2fe0582
M tests/unit/slider/slider_events.js 24 ••••
Txt tests/unit/slider/slider_events.js
  • View file @ e84a318
... ...
@@ -20,7 +20,7 @@ test( "slide", function() {
20 20
 // value (even if same as previous value), via mouse(mouseup) or keyboard(keyup)
21 21
 // or value method/option"
22 22
 test( "change", function() {
23  
-  expect(4);
  23
+  expect(7);
24 24
   
25 25
   var handle;
26 26
   // Test mouseup at end of handle slide (mouse)
... ...
@@ -61,6 +61,17 @@ test( "change", function() {
61 61
     .slider( "value", 0 );
62 62
 
63 63
   reset();
  64
+  // Test values method
  65
+  el = $( "<div></div>" )
  66
+    .slider({
  67
+      values: [ 10, 20 ],
  68
+      change: function(event, ui) {
  69
+        ok( true, "change triggered by values method" );
  70
+      }
  71
+    })
  72
+    .slider( "values", [80, 90] );
  73
+
  74
+  reset();
64 75
   // Test value option
65 76
   el = $( "<div></div>" )
66 77
     .slider({
... ...
@@ -70,6 +81,17 @@ test( "change", function() {
70 81
     })
71 82
     .slider( "option", "value", 0 );
72 83
 
  84
+  reset();
  85
+  // Test values option
  86
+  el = $( "<div></div>" )
  87
+    .slider({
  88
+      values: [ 10, 20 ],
  89
+      change: function(event, ui) {
  90
+        ok( true, "change triggered by values option" );
  91
+      }
  92
+    })
  93
+    .slider( "option", "values", [80, 90] );
  94
+
73 95
 });
74 96
 
75 97
 test( "stop", function() {

0 notes on commit e84a318

Please log in to comment.
Blog | Support | Training | Contact | API | Status | Twitter | Help | Security
© 2010 GitHub Inc. All rights reserved. | Terms of Service | Privacy Policy
Powered by the Dedicated Servers and
Cloud Computing of Rackspace Hosting®
Dedicated Server