Likes feature

Because that test was made before I created the model :) You're totally
right, but the work is not finished, I'll ping you next week.

-- 
Javier Arce



On Fri, Dec 5, 2014 at 6:59 PM, javi santana <notifications@github.com>
wrote:

> In lib/assets/test/spec/cartodb/dashboard/visualizations.spec.js:
>
> > @@ -204,10 +204,18 @@ describe("Dashboard visualizations view", function() {
> >
> >      });
> >
> > +    it("should allow to like a visualization", function() {
> > +      visualizations.reset([ generateVisData('vis_name1', 'paco', 3) ]);
> > +      var vis_item = _.find(view._subviews, function(v) {
> > +        return v instanceof cdb.admin.dashboard.VisualizationItem
> > +      });
> > +      spyOn(vis_item, '_onLikeClick');
> > +      vis_item.delegateEvents();
> > +      vis_item.$('.js-like').click();
> > +      expect(vis_item._onLikeClick).toHaveBeenCalled();
>
> why don't check the like model directly?
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/CartoDB/cartodb/pull/1347/files#r21387769>.
>