Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 10e5d86a37
Fetching contributors…

Cannot retrieve contributors at this time

24 lines (19 sloc) 0.715 kb
describe 'App.Models.Post', ->
buildPost = (options) ->
new App.Models.Post(options)
describe '#title', ->
it 'returns the correct value', ->
post = buildPost title: 'Great title'
expect(post.title()).toEqual 'Great title'
describe '#body', ->
it 'returns the correct value', ->
post = buildPost body: 'Great body'
expect(post.body()).toEqual 'Great body'
describe '#domId', ->
it 'returns the correct value', ->
post = buildPost dom_id: 'post_1'
expect(post.domId()).toEqual 'post_1'
describe '#authorName', ->
it 'returns the correct value', ->
post = buildPost author_name: 'John Doe'
expect(post.authorName()).toEqual 'John Doe'
Jump to Line
Something went wrong with that request. Please try again.