Commit 2adc3c358184763e34911f55a8773c23100e0d50
1 parent
67a7c282
Exists in
master
and in
28 other branches
ActionItem918: fixing test that fails on etch
Showing
1 changed file
with
3 additions
and
2 deletions
Show diff stats
test/unit/content_viewer_helper_test.rb
| ... | ... | @@ -4,6 +4,7 @@ class ContentViewerHelperTest < Test::Unit::TestCase |
| 4 | 4 | |
| 5 | 5 | include ActionView::Helpers::TagHelper |
| 6 | 6 | include ContentViewerHelper |
| 7 | + include DatesHelper | |
| 7 | 8 | |
| 8 | 9 | def setup |
| 9 | 10 | @profile = create_user('blog_helper_test').person |
| ... | ... | @@ -14,13 +15,13 @@ class ContentViewerHelperTest < Test::Unit::TestCase |
| 14 | 15 | blog = Blog.create!(:name => 'Blog test', :profile => profile) |
| 15 | 16 | post = TextileArticle.create!(:name => 'post test', :profile => profile, :parent => blog) |
| 16 | 17 | result = article_title(post) |
| 17 | - assert_match /#{post.created_at}, by #{profile.identifier}/, result | |
| 18 | + assert_match /#{show_date(post.created_at)}, by #{profile.identifier}/, result | |
| 18 | 19 | end |
| 19 | 20 | |
| 20 | 21 | should 'not display created-at for non-blog posts' do |
| 21 | 22 | article = TextileArticle.create!(:name => 'article for test', :profile => profile) |
| 22 | 23 | result = article_title(article) |
| 23 | - assert_no_match /#{article.created_at}, by #{profile.identifier}/, result | |
| 24 | + assert_no_match /#{show_date(article.created_at)}, by #{profile.identifier}/, result | |
| 24 | 25 | end |
| 25 | 26 | |
| 26 | 27 | should 'create link on title of blog posts' do | ... | ... |