From c733d256516bde678fc0f6c92ff75f35caa9d564 Mon Sep 17 00:00:00 2001 From: John Reilly Date: Fri, 10 Jan 2014 13:38:25 +0000 Subject: [PATCH] jQuery: scrollLeft /scrollTop test suites --- jquery/jquery-tests.ts | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/jquery/jquery-tests.ts b/jquery/jquery-tests.ts index 35a954e95..0fed71bf4 100644 --- a/jquery/jquery-tests.ts +++ b/jquery/jquery-tests.ts @@ -1814,6 +1814,20 @@ function test_outerWidth() { " , outerWidth( true ):" + p.outerWidth(true)); } +function test_scrollLeft() { + var p = $("p:first"); + $("p:last").text("scrollLeft:" + p.scrollLeft()); + + $("div.demo").scrollLeft(300); +} + +function test_scrollTop() { + var p = $("p:first"); + $("p:last").text("scrollTop:" + p.scrollTop()); + + $("div.demo").scrollTop(300); +} + function test_position() { var p = $("p:first"); var position = p.position();