Skip to content

Commit

Permalink
Re-arrange similar tests under each other
Browse files Browse the repository at this point in the history
  • Loading branch information
valchev committed Oct 8, 2015
1 parent 7b5b3ee commit ba6fd31
Showing 1 changed file with 17 additions and 17 deletions.
34 changes: 17 additions & 17 deletions tests/virtuallist/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,23 @@
asyncDataSource.read();
});

asyncTest("listBound event is fired after all values are prefetched (multi selection)", 3, function() {
var virtualList = new VirtualList(container, $.extend(virtualSettings, {
selectable: "multiple",
valueMapper: function(o) {
o.success([7, 256]);
},
value: [7, 256],
listBound: function() {
start();
equal(virtualList.value().length, 2);
equal(virtualList.select().length, 2);
equal(virtualList.selectedDataItems().length, 2);
}
}));
asyncDataSource.read();
});

asyncTest("listBound event is fired when range is changed", 3, function() {
var virtualList = new VirtualList(container, $.extend(virtualSettings, {
selectable: true,
Expand All @@ -231,23 +248,6 @@
});
});

asyncTest("listBound event is fired after all values are prefetched (multi selection)", 3, function() {
var virtualList = new VirtualList(container, $.extend(virtualSettings, {
selectable: "multiple",
valueMapper: function(o) {
o.success([7, 256]);
},
value: [7, 256],
listBound: function() {
start();
equal(virtualList.value().length, 2);
equal(virtualList.select().length, 2);
equal(virtualList.selectedDataItems().length, 2);
}
}));
asyncDataSource.read();
});

asyncTest("fires the activate event", 1, function() {
var virtualList = new VirtualList(container, $.extend(virtualSettings, {
activate: function() {
Expand Down

0 comments on commit ba6fd31

Please sign in to comment.