r1956 - trunk/tests/unit/draggable
Author: rdworth
Date: Sun Feb 1 22:34:44 2009
New Revision: 1956
Added:
trunk/tests/unit/draggable/draggable_core.js
- copied unchanged from r1953,
/trunk/tests/unit/draggable/draggable.js
Removed:
trunk/tests/unit/draggable/defaults.js
trunk/tests/unit/draggable/draggable.js
Modified:
trunk/tests/unit/draggable/draggable.html
trunk/tests/unit/draggable/draggable_defaults.js
trunk/tests/unit/draggable/draggable_tickets.js
Log:
draggable unit tests: cleanup
Modified: trunk/tests/unit/draggable/draggable.html
==============================================================================
--- trunk/tests/unit/draggable/draggable.html (original)
+++ trunk/tests/unit/draggable/draggable.html Sun Feb 1 22:34:44 2009
@@ -12,8 +12,7 @@
<script type="text/javascript"
src="../../../external/qunit/testrunner.js"></script>
<script type="text/javascript"
src="../../../external/simulate/jquery.simulate.js"></script>
- <script type="text/javascript" src="defaults.js"></script>
- <script type="text/javascript" src="draggable.js"></script>
+ <script type="text/javascript" src="draggable_core.js"></script>
<script type="text/javascript" src="draggable_defaults.js"></script>
<script type="text/javascript" src="draggable_events.js"></script>
<script type="text/javascript" src="draggable_methods.js"></script>
Modified: trunk/tests/unit/draggable/draggable_defaults.js
==============================================================================
--- trunk/tests/unit/draggable/draggable_defaults.js (original)
+++ trunk/tests/unit/draggable/draggable_defaults.js Sun Feb 1 22:34:44
2009
@@ -1,17 +1,35 @@
/*
* draggable_defaults.js
*/
-(function($) {
-module("draggable: defaults");
+var draggable_defaults = {
+ appendTo: "parent",
+ axis: false,
+ cancel: ":input,option",
+ connectToSortable: false,
+ containment: false,
+ cursor: "auto",
+ cursorAt: false,
+ delay: 0,
+ disabled: false,
+ distance: 1,
+ grid: false,
+ handle: false,
+ helper: "original",
+ iframeFix: false,
+ opacity: false,
+ refreshPositions: false,
+ revert: false,
+ revertDuration: 500,
+ scroll: true,
+ scrollSensitivity: 20,
+ scrollSpeed: 20,
+ scope: "default",
+ snap: false,
+ snapMode: "both",
+ snapTolerance: 20,
+ stack: false,
+ zIndex: false
+};
-test("defaults", function() {
- el = $('<div></div>').draggable();
- $.each(draggable_defaults, function(key, val) {
- var actual = el.data(key + ".draggable"), expected = val;
- same(actual, expected, key);
- });
- el.remove();
-});
-
-})(jQuery);
+commonWidgetTests('draggable', { defaults: draggable_defaults });
Modified: trunk/tests/unit/draggable/draggable_tickets.js
==============================================================================
--- trunk/tests/unit/draggable/draggable_tickets.js (original)
+++ trunk/tests/unit/draggable/draggable_tickets.js Sun Feb 1 22:34:44 2009
@@ -5,8 +5,4 @@
module("draggable: tickets");
-test("#1234", function() {
-
-});
-
})(jQuery);