Commit ee52d3bdbb811defe5b4f3af006cd9d1b85cec3d
1 parent
8aef78e0
Exists in
master
and in
29 other branches
ActionItem154: adding EnterprisesBlock for person.
git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@1402 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing
2 changed files
with
3 additions
and
1 deletions
Show diff stats
app/models/person.rb
| @@ -75,6 +75,7 @@ class Person < Profile | @@ -75,6 +75,7 @@ class Person < Profile | ||
| 75 | # right area | 75 | # right area |
| 76 | self.boxes[2].blocks << TagsBlock.new | 76 | self.boxes[2].blocks << TagsBlock.new |
| 77 | self.boxes[2].blocks << CommunitiesBlock.new | 77 | self.boxes[2].blocks << CommunitiesBlock.new |
| 78 | + self.boxes[2].blocks << EnterprisesBlock.new | ||
| 78 | 79 | ||
| 79 | true | 80 | true |
| 80 | end | 81 | end |
test/unit/person_test.rb
| @@ -137,9 +137,10 @@ class PersonTest < Test::Unit::TestCase | @@ -137,9 +137,10 @@ class PersonTest < Test::Unit::TestCase | ||
| 137 | 137 | ||
| 138 | assert p.boxes[2].blocks.map(&:class).include?(TagsBlock), 'person must have a Tags Block upon creation' | 138 | assert p.boxes[2].blocks.map(&:class).include?(TagsBlock), 'person must have a Tags Block upon creation' |
| 139 | assert p.boxes[2].blocks.map(&:class).include?(CommunitiesBlock), 'person must have a CommunitiesBlock upon creation' | 139 | assert p.boxes[2].blocks.map(&:class).include?(CommunitiesBlock), 'person must have a CommunitiesBlock upon creation' |
| 140 | + assert p.boxes[2].blocks.map(&:class).include?(EnterprisesBlock), 'person must have a EnterprisesBlock upon creation' | ||
| 140 | # TODO check also for a "friends" block | 141 | # TODO check also for a "friends" block |
| 141 | 142 | ||
| 142 | - assert_equal 5, p.blocks.size | 143 | + assert_equal 6, p.blocks.size |
| 143 | end | 144 | end |
| 144 | 145 | ||
| 145 | end | 146 | end |