UPGRADE
1.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
0 - All modified code have the tag UPGRADE on it.
1 - I Changed acts_as_versioned plugin code to the new one:
http://github.com/technoweenie/acts_as_versioned/tree/master
2 - I removed the 'build_person' calls after create the user on UserTest
3 - The settings_items method generated a lot of bugs. Theses bugs are explained here:
Solution 1: http://casperfabricius.com/site/2008/06/12/serialize-doesnt-play-nice-with-rails-21-partial-updates/
Solution 2: http://www.kalzumeus.com/2008/06/28/rails-fails-to-update-serialized-columns-on-save/
The problem is how rails is working with ActiveRecord. The serialization data was not save on database.
I add this code
send(self.class.settings_field.to_s + '_will_change!')
on lib/acts_as_having_settings
I used the solution 1.
I choose solution number 2 for Environment model. I think it is more clear in this situation.
I put the code:
self.partial_updates = false
on Environment model.
4 - acts_as_searchable -> find_by_contents
I solved an incompatibility between paginate and geokit with an work around like this the one explained on the link:
http://groups.google.com/group/will_paginate/browse_thread/thread/1bbb1f0c5810f1c1
5 - The test of this method 'theme_include' of application helper was not passing.
I changed the tests
- "should 'render theme footer' do"
- " should 'ignore unexisting theme footer' do"
to make the test usefull
6 - I changed the way as the product is created on ManageProducts controller. I removed the line:
@product.build_image unless @product.image
because the image was never saved. It don't have valid values to be saved.