mirror of
https://github.com/koalyptus/TableFilter.git
synced 2024-05-18 06:16:39 +02:00
Added date filtering test case with data range and operators
This commit is contained in:
parent
44af1dc552
commit
9a7e8f6982
|
@ -270,8 +270,24 @@ test('can filter empty value with [nonempty] operator', function(){
|
|||
);
|
||||
});
|
||||
|
||||
// module('Tear-down');
|
||||
// test('can destroy TableFilter DOM elements', function() {
|
||||
// tf.destroy();
|
||||
// deepEqual(tf.isInitialized(), false, 'Filters removed');
|
||||
// });
|
||||
test('can filter date with date range with operators', function(){
|
||||
// setup
|
||||
tf.clearFilters();
|
||||
|
||||
// act
|
||||
tf.setFilterValue(2, '<3-jan-2014 && >=23-Oct-2007');
|
||||
tf.filter();
|
||||
|
||||
// assert
|
||||
deepEqual(
|
||||
tf.getFilteredDataCol(2),
|
||||
['23-Oct-2007', '14-Mar-2009'],
|
||||
'Expected match'
|
||||
);
|
||||
});
|
||||
|
||||
module('Tear-down');
|
||||
test('can destroy TableFilter DOM elements', function() {
|
||||
tf.destroy();
|
||||
deepEqual(tf.isInitialized(), false, 'Filters removed');
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue