master
1describe "csx.Views.My.Cakes.CakeView", ->
2 cake = new csx.Models.Cake
3 id: '1'
4 name: 'chocolate'
5 subject = new csx.Views.My.Cakes.CakeView
6 model: cake
7
8 describe "when there are no photos", ->
9 beforeEach ->
10 subject.render()
11
12 it 'renders the cake', ->
13 expect(subject.$el.html()).toMatch(/chocolate/)
14
15 it 'does not display any photos', ->
16 expect(subject.$el.html()).not.toMatch(/img/)