From 1e27bb80202eaddc379727676062923b4ba6d523 Mon Sep 17 00:00:00 2001 From: AntonioTerceiro Date: Fri, 1 Aug 2008 22:51:05 +0000 Subject: [PATCH] ActionItem629: Debian etch porting --- app/models/my_network_block.rb | 2 +- test/unit/my_network_block_test.rb | 2 +- test/unit/profile_test.rb | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/models/my_network_block.rb b/app/models/my_network_block.rb index 3a6c868..9b16a4c 100644 --- a/app/models/my_network_block.rb +++ b/app/models/my_network_block.rb @@ -17,7 +17,7 @@ class MyNetworkBlock < Block content_tag('li', link_to(n_( 'One article published', '%d articles published', owner.articles.count) % owner.articles.count, owner.public_profile_url.merge(:action => 'sitemap') )) + content_tag('li', link_to(n__('One friend', '%d friends', owner.friends.count) % owner.friends.count, owner.public_profile_url.merge(:action => 'friends'))) + content_tag('li', link_to(n__('One community', '%d communities', owner.communities.count) % owner.communities.count, owner.public_profile_url.merge(:action => 'communities'))) + - content_tag('li', link_to(n_('One tag', '%d tags', owner.tags.count) % owner.tags.count, owner.public_profile_url.merge(:action => 'tags'))) + content_tag('li', link_to(n_('One tag', '%d tags', owner.tags.size) % owner.tags.size, owner.public_profile_url.merge(:action => 'tags'))) ) end diff --git a/test/unit/my_network_block_test.rb b/test/unit/my_network_block_test.rb index 3dea326..13db1a8 100644 --- a/test/unit/my_network_block_test.rb +++ b/test/unit/my_network_block_test.rb @@ -47,7 +47,7 @@ class MyNetworkBlockTest < ActiveSupport::TestCase should 'count tags' do mock_tags = mock owner.stubs(:tags).returns(mock_tags) - mock_tags.stubs(:count).returns(436) + mock_tags.stubs(:size).returns(436) assert_tag_in_string block.content, :tag => 'li', :descendant => { :tag => 'a', :content => '436 tags', :attributes => { :href => /\profile\/testuser\/tags/ }} end diff --git a/test/unit/profile_test.rb b/test/unit/profile_test.rb index b839ae9..ce40629 100644 --- a/test/unit/profile_test.rb +++ b/test/unit/profile_test.rb @@ -318,7 +318,7 @@ class ProfileTest < Test::Unit::TestCase end should 'provide tag count' do - assert_equal 0, Profile.new.tags.count + assert_equal 0, Profile.new.tags.size end should 'have administator role' do -- libgit2 0.21.2