aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/resizable/resizable_options.js
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unit/resizable/resizable_options.js')
-rw-r--r--tests/unit/resizable/resizable_options.js29
1 files changed, 29 insertions, 0 deletions
diff --git a/tests/unit/resizable/resizable_options.js b/tests/unit/resizable/resizable_options.js
index 2b66fda3e..d68294845 100644
--- a/tests/unit/resizable/resizable_options.js
+++ b/tests/unit/resizable/resizable_options.js
@@ -375,6 +375,35 @@ test("ui-resizable-nw { handles: 'all', minWidth: 60, minHeight: 60, maxWidth: 1
equal( target.height(), 100, "compare maxHeight" );
});
+
+test( "custom handles { handles: { 's': $('#resizer1'), containment: 'parent' }", function () {
+ expect( 2 );
+
+ var handle = "#resizer1",
+ target = $( "#resizable1" ).resizable({ handles: { "s": $( "#resizer1" ) }, containment: "parent" });
+
+ TestHelpers.resizable.drag( handle, 0, 70 );
+ equal( target.height(), 170, "compare height" );
+
+ TestHelpers.resizable.drag( handle, 0, -70 );
+ equal( target.height(), 100, "compare height" );
+});
+
+
+test( "custom handles { handles: { 's': $('#resizer1')[0], containment: 'parent' }", function () {
+ expect( 2 );
+
+ var handle = "#resizer1",
+ target = $( "#resizable1" ).resizable({ handles: { "s": $( "#resizer1" )[ 0 ] }, containment: "parent" });
+
+ TestHelpers.resizable.drag( handle, 0, 70 );
+ equal( target.height(), 170, "compare height" );
+
+ TestHelpers.resizable.drag( handle, 0, -70 );
+ equal( target.height(), 100, "compare height" );
+});
+
+
test("zIndex, applied to all handles", function() {
expect(8);