/*! * TableSorter QUnit Testing */ /*jshint unused: false */ /*global QUnit: false, JSHINT: false, ok: false, start: false, deepEqual: false, asyncTest: false */ /* Core plugin tested ======================== OPTIONS: cssAsc, cssChildRow, cssDesc, cssHeader, cssHeaderRow, cssInfoBlock, dateFormat, emptyTo, headerList, headers, ignoreCase, initialized, parsers, sortList, sortLocaleCompare, sortReset, stringTo, tableClass, usNumberFormat, widgets (just zebra), sortAppend, sortForce, sortMultiSortKey, sortResetKey, numberSorter METHODS: addRows, applyWidgets, destroy, sorton, sortReset, update/updateRow, updateAll, updateCell EVENTS: initialized, sortBegin, sortEnd, sortStart, updateComplete Not yet tested ========================= OPTIONS: cancelSelection, cssIcon, cssProcessing, debug, delayInit, headerTemplate, initWidgets, onRenderHeader, onRenderTemplate, selectorHeaders, selectorRemove, selectorSort, serverSideSorting, showProcessing, sortInitialOrder, sortRestart, strings, textExtraction, textSorter, theme, widthFixed, widgets (also need priority testing) METHODS: appendCache, applyWidgetId, sort, refreshWidgets EVENTS: - */ $(function(){ var ts = $.tablesorter, // filter widget table $table = $('#testblock').html('
Rank | ' + 'First Name | ' + 'Last Name | ' + 'Age | ' + 'Total | ' + 'Discount | ' + 'Date | ' + '
---|---|---|---|---|---|---|
1 | Philip Aaron Wong | Johnson Sr Esq | 25 | $5.95 | 22% | Jun 26, 2004 7:22 AM |
11 | Aaron | Hibert | 12 | $2.99 | 5% | Aug 21, 2009 12:21 PM |
12 | Brandon Clark | Henry Jr | 51 | $42.29 | 18% | Oct 13, 2000 1:15 PM |
111 | Peter | Parker | 28 | $9.99 | 20% | Jul 6, 2006 8:14 AM |
21 | John | Hood | 33 | $19.99 | 25% | Dec 10, 2002 5:14 AM |
013 | Clark | Kent Sr. | 18 | $15.89 | 44% | Jan 12, 2003 11:14 AM |
005 | Bruce | Almighty Esq | 45 | $153.19 | 44% | Jan 18, 2021 9:12 AM |
10 | Alex | Dumass | 13 | $5.29 | 4% | Jan 8, 2012 5:11 PM |
16 | Jim | Franco | 24 | $14.19 | 14% | Jan 14, 2004 11:23 AM |
166 | Bruce Lee | Evans | 22 | $13.19 | 11% | Jan 18, 2007 9:12 AM |
100 | Brenda Dexter | McMasters | 18 | $55.20 | 15% | Feb 12, 2010 7:23 PM |
55 | Dennis | Bronson | 65 | $123.00 | 32% | Jan 20, 2001 1:12 PM |
9 | Martha | delFuego | 25 | $22.09 | 17% | Jun 11, 2011 10:55 AM |