Skip to content

Commit 75105f6

Browse files
committed
Slider tests: Fixed style checks for orientation test.
1 parent 174df61 commit 75105f6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/unit/slider/slider_options.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ test("min", function() {
5151

5252
test("orientation", function() {
5353
expect( 6 );
54-
el = $('<div></div>');
54+
el = $('#slider1');
5555

5656
options = {
5757
max: 2,
@@ -65,7 +65,7 @@ test("orientation", function() {
6565
el.slider(options).slider("option", "orientation", "horizontal");
6666
ok(el.is('.ui-slider-horizontal'), "horizontal slider has class .ui-slider-horizontal");
6767
ok(!el.is('.ui-slider-vertical'), "horizontal slider does not have class .ui-slider-vertical");
68-
equal(handle().css('left'), percentVal + '%', "horizontal slider handle is positioned with left: %");
68+
equal(handle()[0].style.left, percentVal + '%', "horizontal slider handle is positioned with left: %");
6969

7070
el.slider('destroy');
7171

@@ -81,7 +81,7 @@ test("orientation", function() {
8181
el.slider(options).slider("option", "orientation", "vertical");
8282
ok(el.is('.ui-slider-vertical'), "vertical slider has class .ui-slider-vertical");
8383
ok(!el.is('.ui-slider-horizontal'), "vertical slider does not have class .ui-slider-horizontal");
84-
equal(handle().css('bottom'), percentVal + '%', "vertical slider handle is positioned with bottom: %");
84+
equal(handle()[0].style.bottom, percentVal + '%', "vertical slider handle is positioned with bottom: %");
8585

8686
el.slider('destroy');
8787

0 commit comments

Comments
 (0)