aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/resizable
diff options
context:
space:
mode:
authorMike Sherov <mike.sherov@gmail.com>2012-11-03 16:17:16 -0400
committerMike Sherov <mike.sherov@gmail.com>2012-11-03 16:17:16 -0400
commit3df9ea29e644a3dd6345161513dae5823d9b0460 (patch)
tree08bdc053f90d110cb4af39c4de464d92ad8142c6 /tests/unit/resizable
parent68ad80c2922daccba773a9adafe9fb5efcb129a2 (diff)
downloadjquery-ui-3df9ea29e644a3dd6345161513dae5823d9b0460.tar.gz
jquery-ui-3df9ea29e644a3dd6345161513dae5823d9b0460.zip
Dev: remove globals from tests and moved test helpers to correct location - Fixed #8770 Dev: Remove globals and Standardize Test Suite
Diffstat (limited to 'tests/unit/resizable')
-rw-r--r--tests/unit/resizable/resizable.html1
-rw-r--r--tests/unit/resizable/resizable_core.js16
-rw-r--r--tests/unit/resizable/resizable_test_helpers.js15
3 files changed, 16 insertions, 16 deletions
diff --git a/tests/unit/resizable/resizable.html b/tests/unit/resizable/resizable.html
index 50099efee..eca465ae9 100644
--- a/tests/unit/resizable/resizable.html
+++ b/tests/unit/resizable/resizable.html
@@ -26,6 +26,7 @@
<script src="resizable_events.js"></script>
<script src="resizable_methods.js"></script>
<script src="resizable_options.js"></script>
+ <script src="resizable_test_helpers.js"></script>
<script src="../swarminject.js"></script>
</head>
diff --git a/tests/unit/resizable/resizable_core.js b/tests/unit/resizable/resizable_core.js
index f4e6cdedd..01f15bd4b 100644
--- a/tests/unit/resizable/resizable_core.js
+++ b/tests/unit/resizable/resizable_core.js
@@ -2,22 +2,6 @@
* resizable_core.js
*/
-TestHelpers.resizable = {
- drag: function(el, dx, dy, complete) {
-
- // speed = sync -> Drag syncrhonously.
- // speed = fast|slow -> Drag asyncrhonously - animated.
-
- //this mouseover is to work around a limitation in resizable
- //TODO: fix resizable so handle doesn't require mouseover in order to be used
- $(el).simulate("mouseover");
-
- return $(el).simulate("drag", {
- dx: dx||0, dy: dy||0, speed: 'sync', complete: complete
- });
- }
-};
-
(function($) {
module("resizable: core");
diff --git a/tests/unit/resizable/resizable_test_helpers.js b/tests/unit/resizable/resizable_test_helpers.js
new file mode 100644
index 000000000..fe6c84900
--- /dev/null
+++ b/tests/unit/resizable/resizable_test_helpers.js
@@ -0,0 +1,15 @@
+TestHelpers.resizable = {
+ drag: function(el, dx, dy, complete) {
+
+ // speed = sync -> Drag syncrhonously.
+ // speed = fast|slow -> Drag asyncrhonously - animated.
+
+ //this mouseover is to work around a limitation in resizable
+ //TODO: fix resizable so handle doesn't require mouseover in order to be used
+ $(el).simulate("mouseover");
+
+ return $(el).simulate("drag", {
+ dx: dx||0, dy: dy||0, speed: 'sync', complete: complete
+ });
+ }
+}; \ No newline at end of file