spec/javascripts/TransistorBackboneCollectionSpec.js in transistor-0.1.12 vs spec/javascripts/TransistorBackboneCollectionSpec.js in transistor-0.1.13
- old
+ new
@@ -124,17 +124,17 @@
['set', ['news', [{a: 12}, {b: 13}]]]
]);
});
it('delegates model change events to update', function () {
- radio.trigger('news', 'init', [{id: 100, a:2, b:3}, {id: 101, a:12, b:23}]);
+ radio.trigger('news', 'init', [{id: 100, a:2, b:3}, {id: 101, object: 133, a:12, b:23}]);
var model = collection.get(101);
- model.set('a', 24);
+ model.set('object', {attr: 24});
assertEqual(control.calls, [
- ['update', ['news', 101, {a: 24, b:23}]]
+ ['update', ['news', 101, {attr: 24}]]
]);
})
});
describe("init event", function () {