diff options
Diffstat (limited to 'tests/unit')
-rw-r--r-- | tests/unit/accordion/accordion_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/accordion/accordion_defaults_deprecated.js | 2 | ||||
-rw-r--r-- | tests/unit/autocomplete/autocomplete_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/button/button_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/datepicker/datepicker_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/dialog/dialog_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/draggable/draggable_defaults.js | 68 | ||||
-rw-r--r-- | tests/unit/droppable/droppable_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/menu/menu_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/progressbar/progressbar_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/resizable/resizable_defaults.js | 52 | ||||
-rw-r--r-- | tests/unit/selectable/selectable_defaults.js | 28 | ||||
-rw-r--r-- | tests/unit/slider/slider_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/sortable/sortable_defaults.js | 64 | ||||
-rw-r--r-- | tests/unit/spinner/spinner_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/tabs/tabs_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/tabs/tabs_defaults_deprecated.js | 2 | ||||
-rw-r--r-- | tests/unit/testsuite.js | 2 | ||||
-rw-r--r-- | tests/unit/tooltip/tooltip_defaults.js | 2 |
19 files changed, 113 insertions, 129 deletions
diff --git a/tests/unit/accordion/accordion_defaults.js b/tests/unit/accordion/accordion_defaults.js index 9ad85bbce..ef24cf25e 100644 --- a/tests/unit/accordion/accordion_defaults.js +++ b/tests/unit/accordion/accordion_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "accordion", { +TestHelpers.commonWidgetTests( "accordion", { defaults: { active: 0, animate: {}, diff --git a/tests/unit/accordion/accordion_defaults_deprecated.js b/tests/unit/accordion/accordion_defaults_deprecated.js index 99f5ac827..22d5e1289 100644 --- a/tests/unit/accordion/accordion_defaults_deprecated.js +++ b/tests/unit/accordion/accordion_defaults_deprecated.js @@ -1,4 +1,4 @@ -commonWidgetTests( "accordion", { +TestHelpers.commonWidgetTests( "accordion", { defaults: { active: 0, animate: null, diff --git a/tests/unit/autocomplete/autocomplete_defaults.js b/tests/unit/autocomplete/autocomplete_defaults.js index ac83eaea4..c090ce4df 100644 --- a/tests/unit/autocomplete/autocomplete_defaults.js +++ b/tests/unit/autocomplete/autocomplete_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "autocomplete", { +TestHelpers.commonWidgetTests( "autocomplete", { defaults: { appendTo: "body", autoFocus: false, diff --git a/tests/unit/button/button_defaults.js b/tests/unit/button/button_defaults.js index 96c7e5bfa..ef22d3011 100644 --- a/tests/unit/button/button_defaults.js +++ b/tests/unit/button/button_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "button", { +TestHelpers.commonWidgetTests( "button", { defaults: { disabled: null, icons: { diff --git a/tests/unit/datepicker/datepicker_defaults.js b/tests/unit/datepicker/datepicker_defaults.js index 4243cf187..28e150791 100644 --- a/tests/unit/datepicker/datepicker_defaults.js +++ b/tests/unit/datepicker/datepicker_defaults.js @@ -6,4 +6,4 @@ var datepicker_defaults = { disabled: false }; -//commonWidgetTests('datepicker', { defaults: datepicker_defaults }); +//TestHelpers.commonWidgetTests('datepicker', { defaults: datepicker_defaults }); diff --git a/tests/unit/dialog/dialog_defaults.js b/tests/unit/dialog/dialog_defaults.js index 9f2e4c6a8..623908da7 100644 --- a/tests/unit/dialog/dialog_defaults.js +++ b/tests/unit/dialog/dialog_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "dialog", { +TestHelpers.commonWidgetTests( "dialog", { defaults: { autoOpen: true, buttons: {}, diff --git a/tests/unit/draggable/draggable_defaults.js b/tests/unit/draggable/draggable_defaults.js index 4b0aaca19..b47b139cd 100644 --- a/tests/unit/draggable/draggable_defaults.js +++ b/tests/unit/draggable/draggable_defaults.js @@ -1,36 +1,32 @@ -/* - * draggable_defaults.js - */ - -var draggable_defaults = { - addClasses: true, - 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 -}; - -commonWidgetTests('draggable', { defaults: draggable_defaults }); +TestHelpers.commonWidgetTests( "draggable", { + defaults: { + addClasses: true, + 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 + } +}); diff --git a/tests/unit/droppable/droppable_defaults.js b/tests/unit/droppable/droppable_defaults.js index 5a1a4198c..985dba06d 100644 --- a/tests/unit/droppable/droppable_defaults.js +++ b/tests/unit/droppable/droppable_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "droppable", { +TestHelpers.commonWidgetTests( "droppable", { defaults: { accept: "*", activeClass: false, diff --git a/tests/unit/menu/menu_defaults.js b/tests/unit/menu/menu_defaults.js index 018ac8ccf..ddcdbebf2 100644 --- a/tests/unit/menu/menu_defaults.js +++ b/tests/unit/menu/menu_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "menu", { +TestHelpers.commonWidgetTests( "menu", { defaults: { disabled: false, menus: "ul", diff --git a/tests/unit/progressbar/progressbar_defaults.js b/tests/unit/progressbar/progressbar_defaults.js index 3856e31a0..2f97a78bb 100644 --- a/tests/unit/progressbar/progressbar_defaults.js +++ b/tests/unit/progressbar/progressbar_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "progressbar", { +TestHelpers.commonWidgetTests( "progressbar", { defaults: { disabled: false, value: 0, diff --git a/tests/unit/resizable/resizable_defaults.js b/tests/unit/resizable/resizable_defaults.js index f69e5217c..c46e10781 100644 --- a/tests/unit/resizable/resizable_defaults.js +++ b/tests/unit/resizable/resizable_defaults.js @@ -1,28 +1,24 @@ -/* - * resizable_defaults.js - */ - -var resizable_defaults = { - alsoResize: false, - animate: false, - animateDuration: 'slow', - animateEasing: 'swing', - aspectRatio: false, - autoHide: false, - cancel: ':input,option', - containment: false, - delay: 0, - disabled: false, - distance: 1, - ghost: false, - grid: false, - handles: 'e,s,se', - helper: false, - maxHeight: null, - maxWidth: null, - minHeight: 10, - minWidth: 10, - zIndex: 1000 -}; - -commonWidgetTests('resizable', { defaults: resizable_defaults }); +TestHelpers.commonWidgetTests('resizable', { + defaults: { + alsoResize: false, + animate: false, + animateDuration: 'slow', + animateEasing: 'swing', + aspectRatio: false, + autoHide: false, + cancel: ':input,option', + containment: false, + delay: 0, + disabled: false, + distance: 1, + ghost: false, + grid: false, + handles: 'e,s,se', + helper: false, + maxHeight: null, + maxWidth: null, + minHeight: 10, + minWidth: 10, + zIndex: 1000 + } +}); diff --git a/tests/unit/selectable/selectable_defaults.js b/tests/unit/selectable/selectable_defaults.js index dbf799a43..27714d0ae 100644 --- a/tests/unit/selectable/selectable_defaults.js +++ b/tests/unit/selectable/selectable_defaults.js @@ -1,16 +1,12 @@ -/* - * selectable_defaults.js - */ - -var selectable_defaults = { - appendTo: 'body', - autoRefresh: true, - cancel: ':input,option', - delay: 0, - disabled: false, - distance: 0, - filter: '*', - tolerance: 'touch' -}; - -commonWidgetTests('selectable', { defaults: selectable_defaults }); +TestHelpers.commonWidgetTests('selectable', { + defaults: { + appendTo: 'body', + autoRefresh: true, + cancel: ':input,option', + delay: 0, + disabled: false, + distance: 0, + filter: '*', + tolerance: 'touch' + } +}); diff --git a/tests/unit/slider/slider_defaults.js b/tests/unit/slider/slider_defaults.js index 8049fe969..8a0b347f3 100644 --- a/tests/unit/slider/slider_defaults.js +++ b/tests/unit/slider/slider_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "slider", { +TestHelpers.commonWidgetTests( "slider", { defaults: { animate: false, cancel: ':input,option', diff --git a/tests/unit/sortable/sortable_defaults.js b/tests/unit/sortable/sortable_defaults.js index 7681addad..b5fc05a5d 100644 --- a/tests/unit/sortable/sortable_defaults.js +++ b/tests/unit/sortable/sortable_defaults.js @@ -1,34 +1,30 @@ -/* - * sortable_defaults.js - */ - -var sortable_defaults = { - appendTo: "parent", - axis: false, - cancel: ":input,option", - connectWith: false, - containment: false, - cursor: 'auto', - cursorAt: false, - delay: 0, - disabled: false, - distance: 1, - dropOnEmpty: true, - forcePlaceholderSize: false, - forceHelperSize: false, - grid: false, - handle: false, - helper: "original", - items: "> *", - opacity: false, - placeholder: false, - revert: false, - scroll: true, - scrollSensitivity: 20, - scrollSpeed: 20, - scope: "default", - tolerance: "intersect", - zIndex: 1000 -}; - -commonWidgetTests('sortable', { defaults: sortable_defaults }); +TestHelpers.commonWidgetTests( "sortable", { + defaults: { + appendTo: "parent", + axis: false, + cancel: ":input,option", + connectWith: false, + containment: false, + cursor: "auto", + cursorAt: false, + delay: 0, + disabled: false, + distance: 1, + dropOnEmpty: true, + forcePlaceholderSize: false, + forceHelperSize: false, + grid: false, + handle: false, + helper: "original", + items: "> *", + opacity: false, + placeholder: false, + revert: false, + scroll: true, + scrollSensitivity: 20, + scrollSpeed: 20, + scope: "default", + tolerance: "intersect", + zIndex: 1000 + } +}); diff --git a/tests/unit/spinner/spinner_defaults.js b/tests/unit/spinner/spinner_defaults.js index 0a4e7c236..4f05b1e63 100644 --- a/tests/unit/spinner/spinner_defaults.js +++ b/tests/unit/spinner/spinner_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "spinner", { +TestHelpers.commonWidgetTests( "spinner", { defaults: { culture: null, disabled: false, diff --git a/tests/unit/tabs/tabs_defaults.js b/tests/unit/tabs/tabs_defaults.js index 52b6f8a71..7ffb05da4 100644 --- a/tests/unit/tabs/tabs_defaults.js +++ b/tests/unit/tabs/tabs_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "tabs", { +TestHelpers.commonWidgetTests( "tabs", { defaults: { active: null, collapsible: false, diff --git a/tests/unit/tabs/tabs_defaults_deprecated.js b/tests/unit/tabs/tabs_defaults_deprecated.js index 1a56297e9..fdcff21b3 100644 --- a/tests/unit/tabs/tabs_defaults_deprecated.js +++ b/tests/unit/tabs/tabs_defaults_deprecated.js @@ -1,4 +1,4 @@ -commonWidgetTests( "tabs", { +TestHelpers.commonWidgetTests( "tabs", { defaults: { active: null, ajaxOptions: null, diff --git a/tests/unit/testsuite.js b/tests/unit/testsuite.js index 648b302ee..a877e38af 100644 --- a/tests/unit/testsuite.js +++ b/tests/unit/testsuite.js @@ -56,7 +56,7 @@ function testBasicUsage( widget ) { }); } -window.commonWidgetTests = function( widget, settings ) { +TestHelpers.commonWidgetTests = function( widget, settings ) { module( widget + ": common widget" ); testWidgetDefaults( widget, settings.defaults ); diff --git a/tests/unit/tooltip/tooltip_defaults.js b/tests/unit/tooltip/tooltip_defaults.js index b8b41bf47..d12ee9519 100644 --- a/tests/unit/tooltip/tooltip_defaults.js +++ b/tests/unit/tooltip/tooltip_defaults.js @@ -1,4 +1,4 @@ -commonWidgetTests( "tooltip", { +TestHelpers.commonWidgetTests( "tooltip", { defaults: { content: function() {}, disabled: false, |