diff options
Diffstat (limited to 'tests/unit')
-rw-r--r-- | tests/unit/datepicker/images/calendar.gif | bin | 269 -> 258 bytes | |||
-rw-r--r-- | tests/unit/dialog/dialog_common.js | 2 | ||||
-rw-r--r-- | tests/unit/dialog/dialog_options.js | 2 | ||||
-rw-r--r-- | tests/unit/draggable/draggable_core.js | 25 | ||||
-rw-r--r-- | tests/unit/testsuite.js | 2 |
5 files changed, 28 insertions, 3 deletions
diff --git a/tests/unit/datepicker/images/calendar.gif b/tests/unit/datepicker/images/calendar.gif Binary files differindex d0abaa7c0..52f2863c9 100644 --- a/tests/unit/datepicker/images/calendar.gif +++ b/tests/unit/datepicker/images/calendar.gif diff --git a/tests/unit/dialog/dialog_common.js b/tests/unit/dialog/dialog_common.js index ea4c91767..fc10fabaa 100644 --- a/tests/unit/dialog/dialog_common.js +++ b/tests/unit/dialog/dialog_common.js @@ -4,7 +4,7 @@ TestHelpers.commonWidgetTests( "dialog", { autoOpen: true, buttons: [], closeOnEscape: true, - closeText: "close", + closeText: "Close", disabled: false, dialogClass: "", draggable: true, diff --git a/tests/unit/dialog/dialog_options.js b/tests/unit/dialog/dialog_options.js index 07c2d6860..66aeebde0 100644 --- a/tests/unit/dialog/dialog_options.js +++ b/tests/unit/dialog/dialog_options.js @@ -209,7 +209,7 @@ test("closeText", function() { expect(3); var element = $("<div></div>").dialog(); - equal(element.dialog("widget").find(".ui-dialog-titlebar-close span").text(), "close", + equal(element.dialog("widget").find(".ui-dialog-titlebar-close span").text(), "Close", "default close text"); element.remove(); diff --git a/tests/unit/draggable/draggable_core.js b/tests/unit/draggable/draggable_core.js index 69906b6a7..0389ea9ee 100644 --- a/tests/unit/draggable/draggable_core.js +++ b/tests/unit/draggable/draggable_core.js @@ -139,6 +139,31 @@ test( "#6258: not following mouse when scrolled and using overflow-y: scroll", f }); }); +test( "#9315: Draggable: jumps down with offset of scrollbar", function() { + expect( 2 ); + + var element = $( "#draggable2" ).draggable({ + stop: function( event, ui ) { + equal( ui.position.left, 11, "left position is correct when position is absolute" ); + equal( ui.position.top, 11, "top position is correct when position is absolute" ); + $( "html" ).scrollTop( 0 ).scrollLeft( 0 ); + } + }), + contentToForceScroll = $( "<div>" ).css({ + height: "10000px", + width: "10000px" + }); + + contentToForceScroll.appendTo( "#qunit-fixture" ); + $( "html" ).scrollTop( 300 ).scrollLeft( 300 ); + + element.simulate( "drag", { + dx: 1, + dy: 1, + moves: 1 + }); +}); + test( "#5009: scroll not working with parent's position fixed", function() { expect( 2 ); diff --git a/tests/unit/testsuite.js b/tests/unit/testsuite.js index 6e840f415..cef24e93b 100644 --- a/tests/unit/testsuite.js +++ b/tests/unit/testsuite.js @@ -83,7 +83,7 @@ TestHelpers.testJshint = function( module ) { globals = jshintrc.globals || {}; delete jshintrc.globals; - passed = JSHINT( source, jshintrc, globals ), + passed = JSHINT( source, jshintrc, globals ); errors = $.map( JSHINT.errors, function( error ) { // JSHINT may report null if there are too many errors if ( !error ) { |