[#349,transform][s]: remove transform view and associated code - fixes #349.

This commit is contained in:
Rufus Pollock
2013-05-04 22:13:27 +01:00
parent 6560aa98e1
commit fc79518ba5
13 changed files with 0 additions and 559 deletions

View File

@@ -187,31 +187,6 @@ test('update and delete', function () {
equal(data.records[0].x, memoryData[1].x);
});
test('transform', function () {
var data = [
{a: 1, b: " bla"},
{a: 2, b: "foo "},
{a: 3, b: "bar"}
];
var store = new recline.Backend.Memory.Store(data);
store.transform(function(d) {
d.a = d.a * 10;
return d;
})
equal(store.records[0].a, 10);
equal(store.records[1].a, 20);
});
test('transform deletes', function () {
var data = [{a: 1, b: " bla"},{a: 2, b: "foo "},{a: 3, b: "bar"}];
var store = new recline.Backend.Memory.Store(data);
store.transform(function(d) {
if (d.a == '1') return null;
else return d;
})
equal(store.records.length, 2);
});
})(this.jQuery);
// ======================================