Michael Koziarski
24a8ae4e08
Try to get more useful errors out of the test_line_offset failures
2008-07-15 20:39:36 +02:00
Jeremy Kemper
3c282f3a0a
Ruby 1.9 compat: only eval with block.binding in 1.9, uses more memory than eval with block
2008-07-15 10:42:50 -07:00
Jeremy Kemper
4d76bad387
Ruby 1.9 compat: account for different String#hash
2008-07-15 10:40:33 -07:00
松田 明
bb33432b0f
Ruby 1.9 compat: call Proc#binding explicitly. [ #623 state:resolved]
2008-07-15 10:39:02 -07:00
Adrian Mugnolo
fc89a95193
Add in_groups to ActiveSupport::CoreExtensions::Array::Grouping. [ #579 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-15 15:04:26 +01:00
Tarmo Tänav
c1531ae00d
SQLite: rename_column raises if the column doesn't exist.
...
[#622 state:resolved]
2008-07-14 22:58:22 -07:00
Tarmo Tänav
8c91b767c0
Fixed postgresql limited eager loading for the case where scoped :order was present
2008-07-14 22:44:58 -07:00
gbuesing
3451045658
Fix TimeWithZone unmarshaling: coerce unmarshaled Time instances to utc, because Ruby's marshaling of Time instances doesn't respect the zone
2008-07-14 23:16:39 -05:00
Joshua Peek
7f0346237e
Append a "_" to memoized instance variables
2008-07-14 20:25:09 -05:00
Tarmo Tänav
911c2c3813
Some performance tweaks to ActiveSupport::Memoizable
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2008-07-14 20:23:23 -05:00
Joshua Peek
001c8beb4d
memorize typo
2008-07-14 20:02:59 -05:00
Joshua Peek
dd41f66af5
Include Memoizable in ActionView::Template
2008-07-14 19:51:43 -05:00
Joshua Peek
8a9934a9d9
Added Memoizable mixin for caching simple lazy loaded attributes
2008-07-14 19:50:32 -05:00
Tarmo Tänav
d27dd860c7
Use sub instead of gsub
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2008-07-14 18:02:59 -05:00
Joshua Peek
9dc258d614
Eager load Partial variable_name and counter_name. Tidy up render_partial_collection.
2008-07-14 17:40:58 -05:00
Tiago Macedo
76df9fa068
Fix integer quoting issues in association preload. [ #602 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-14 23:34:19 +01:00
Gabe da Silveira
cd9b24286a
Add assert_sql helper method to check for specific SQL output in Active Record test suite. [ #325 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-14 23:22:39 +01:00
Jeremy Kemper
2d6562d51b
Move dead recompile_template? also
2008-07-14 13:51:59 -07:00
Jeremy Kemper
3fbefecc9c
Remove dead code from merge
2008-07-14 13:47:51 -07:00
Tarmo Tänav
07578ac855
Fixed mysql change_column_default to not make the column always nullable.
...
Also added change_column_null to both mysql and sqlite to keep the api features closer to postgresql.
[#617 state:resolved]
2008-07-14 12:42:01 -07:00
Tarmo Tänav
8f72bc92e2
Fixed test_rename_nonexistent_column for PostgreSQL
...
Also fixed ability to run migration_test.rb alone
[#616 state:resolved]
2008-07-14 12:22:27 -07:00
Jeremy Kemper
c760dbfd31
PostgreSQL: don't dump :limit => 4 for integers
2008-07-14 11:59:46 -07:00
Jeremy Kemper
4e323f6ef0
Fix bad merge
2008-07-14 11:50:07 -07:00
Jeremy Kemper
cdf0f1aa2e
Faster and clearer value_to_boolean
2008-07-14 11:41:56 -07:00
Jeremy Kemper
269c6c6bcf
Cache Module#parent_name
2008-07-14 10:46:16 -07:00
Jeremy Kemper
ae9356ae9e
Cache template loading for performance tests
2008-07-14 10:46:16 -07:00
Jeremy Kemper
425de8db6a
Use instance_method(...) to check whether the method exists
2008-07-14 10:46:15 -07:00
Jeremy Kemper
2167f95d85
Restore the more readable before_ and after_filters methods since they aren't called frequently
2008-07-14 10:11:53 -07:00
David Heinemeier Hansson
3037022789
Fixed that create database statements would always include "DEFAULT NULL" (Nick Sieger) [ #334 status:committed]
2008-07-14 10:12:54 -05:00
Sebastian A. Espindola
0176e6adb3
Added db:charset support to PostgreSQL. [ #556 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-14 04:11:52 +01:00
Tim Pope
5c08607082
Make script/plugin install <plugin> -r <revision> option work with git based plugins. [ #257 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-14 03:47:22 +01:00
David Dollar
e0750d6a5c
Add :accessible option to Associations for allowing mass assignments using hash. [ #474 state:resolved]
...
Allows nested Hashes (i.e. from nested forms) to hydrate the appropriate
ActiveRecord models.
class Post < ActiveRecord::Base
belongs_to :author, :accessible => true
has_many :comments, :accessible => true
end
post = Post.create({
:title => 'Accessible Attributes',
:author => { :name => 'David Dollar' },
:comments => [
{ :body => 'First Post!' },
{ :body => 'Nested Hashes are great!' }
]
})
post.comments << { :body => 'Another Comment' }
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-14 02:53:21 +01:00
Jason Dew
c6f397c5ce
Add block syntax to HasManyAssociation#build. [ #502 state:resolve]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-14 02:24:12 +01:00
Rhett Sutphin
d72c66532f
Make fixture accessors work when fixture name is not same as the table name. [ #124 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-14 02:01:52 +01:00
Jacek Becela
697ee1a50d
Enable loading fixtures from arbitrary locations. [ #586 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-14 01:32:01 +01:00
Pratik Naik
9783e66cad
Slightly faster DateTime#to_json. [ #598 state:resolved] [Alex Zepeda]
2008-07-14 01:02:07 +01:00
rsl
95812d5eaf
Ensure :index works with fields_for select methods. [ #518 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-14 00:55:57 +01:00
Tapajós
0d241f4434
Use full path in database tasks so commands will work outside of Rails root [ #612 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2008-07-13 14:19:03 -05:00
Joshua Peek
68fe898189
Check first render format and extension. Fixes failing ActionMailer test.
2008-07-13 14:05:21 -05:00
Joshua Peek
26bc867151
Small tweak to e0fef66
2008-07-13 14:00:40 -05:00
Joshua Peek
e0fef66149
Made ActionView::Base#first_render a little more private. And added _last_render to track the most recent render. Will fix #609 as a side effect. [ #609 state:resolved]
2008-07-13 13:26:48 -05:00
Joshua Peek
99cc85bc09
Set config.action_view.warn_cache_misses = true to receive a warning if you perform an action that results in an expensive disk operation that could be cached
2008-07-12 15:31:50 -05:00
Joshua Peek
73b34e9f75
Refactor template preloading. New abstractions include Renderable mixins and a refactored Template class.
2008-07-12 14:33:46 -05:00
Joshua Peek
30204c4e66
Set global ActionController::Base.view_paths for test cases
2008-07-12 14:11:51 -05:00
Joshua Peek
65fb2e76f2
Removed a few implementation specific view path tests
2008-07-12 12:17:10 -05:00
Joshua Peek
b603de0882
Improve test coverage and create fixtures for RenderPartialWithRecordIdentificationTests
2008-07-12 12:17:10 -05:00
Daniel Guettler
f90eb81c65
Ensure script/generate finds generators from symlinked plugins. [ #449 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-12 17:51:48 +01:00
Michael Koziarski
e53f5fe696
Restore support for partial matches in assert_redirected_to
...
If both the actual redirection and the asserted redirection are hashes, succeed if the asserted redirection is a strict subset of the actual redirection.
2008-07-12 11:42:41 +02:00
Johan Sørensen
50b5c6845e
Ensure mail_to label is obfuscated for javascript encoding. [ #294 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-12 01:04:18 +01:00
Micah Wedemeyer
5e2e1ed9ff
Ensure MysqlAdapter allows SSL connection when only sslca is supplied. [ #253 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2008-07-11 23:52:41 +01:00