Commit 650f72e758e25e2893d56b2906732642461d71bf

Authored by Antonio Terceiro
1 parent 6c8063ab

ActionItem1049: fixing one more test

Showing 1 changed file with 2 additions and 2 deletions   Show diff stats
test/unit/blog_helper_test.rb
@@ -40,8 +40,8 @@ class BlogHelperTest < Test::Unit::TestCase @@ -40,8 +40,8 @@ class BlogHelperTest < Test::Unit::TestCase
40 blog.children << published_post = TextileArticle.create!(:name => 'Second post', :profile => profile, :parent => blog, :published => true) 40 blog.children << published_post = TextileArticle.create!(:name => 'Second post', :profile => profile, :parent => blog, :published => true)
41 41
42 expects(:display_post).with(anything).returns('POST') 42 expects(:display_post).with(anything).returns('POST')
43 - expects(:content_tag).with('div', 'POST', :class => 'blog-post position-2 last', :id => "post-#{published_post.id}").returns('RESULT')  
44 - expects(:content_tag).with('div', 'POST', :class => 'blog-post position-1 first', :id => "post-#{unpublished_post.id}").never 43 + expects(:content_tag).with('div', 'POST', has_entries(:id => "post-#{published_post.id}")).returns('RESULT')
  44 + expects(:content_tag).with('div', 'POST', has_entries(:id => "post-#{unpublished_post.id}")).never
45 45
46 assert_equal 'RESULT', list_posts(nil, blog.posts) 46 assert_equal 'RESULT', list_posts(nil, blog.posts)
47 end 47 end