| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Signed-off-by: wycats <wycats@gmail.com>
|
|
|
|
|
|
| |
Obie Fernandez, updated touch! to act as a thin wrapper to touch. [#2520 state:resolved]"
This reverts commit 3a875e618487a06a56f6cf912cf5440f294921cc.
|
|
|
|
|
| |
Fernandez, updated touch! to act as a thin wrapper to touch. [#2520 state:resolved]
Signed-off-by: wycats <wycats@gmail.com>
|
|
|
|
|
|
| |
[#918 state:resolved]
Signed-off-by: wycats <wycats@gmail.com>
|
|\ |
|
| |
| |
| |
| | |
remove railtie_name and engine_name and allow to set the configuration object.
|
| |
| |
| |
| | |
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| | |
|
| | |
|
| |
| |
| |
| | |
values, instead of creating multiple relation objects.
|
| | |
|
| |
| |
| |
| | |
Signed-off-by: wycats <wycats@gmail.com>
|
| |
| |
| |
| | |
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| | |
offset are always defined, no need to test that.
[#4253 state:committed]
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
|
| |
| |
| |
| |
| |
| | |
state:resolved]
Signed-off-by: wycats <wycats@gmail.com>
|
| |
| |
| |
| | |
Signed-off-by: wycats <wycats@gmail.com>
|
| |
| |
| |
| | |
Signed-off-by: wycats <wycats@gmail.com>
|
| |
| |
| |
| | |
Signed-off-by: wycats <wycats@gmail.com>
|
| | |
|
| |
| |
| |
| | |
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
|
| |
| |
| |
| | |
Signed-off-by: wycats <wycats@gmail.com>
|
| |
| |
| |
| |
| |
| | |
[#4193 state:resolved]
Signed-off-by: wycats <wycats@gmail.com>
|
| |
| |
| |
| | |
Signed-off-by: Rizwan Reza <rizwanreza@gmail.com>
|
|/
|
|
| |
Signed-off-by: Rizwan Reza <rizwanreza@gmail.com>
|
|
|
|
| |
Signed-off-by: wycats <wycats@gmail.com>
|
|
|
|
|
|
| |
initialize
Signed-off-by: wycats <wycats@gmail.com>
|
|
|
|
| |
Signed-off-by: wycats <wycats@gmail.com>
|
|
|
|
|
|
|
|
| |
delegate it to @target in association collections
[#4165 state:committed]
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
|
|
|
|
|
|
| |
[#4142 state:committed]
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
|
|
|
|
| |
Signed-off-by: wycats <wycats@gmail.com>
|
| |
|
|
|
|
|
|
| |
option
Signed-off-by: José Valim <jose.valim@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
add lazy_load_hooks.rb, which allows us to declare code that
should be run at some later time. For instance, this allows
us to defer requiring ActiveRecord::Base at boot time purely
to apply configuration. Instead, we register a hook that should
apply configuration once ActiveRecord::Base is loaded.
With these changes, brings down total boot time of a
new app to 300ms in production and 400ms in dev.
TODO: rename base_hook
|
|
|
|
| |
Signed-off-by: wycats <wycats@gmail.com>
|
|
|
|
| |
Signed-off-by: wycats <wycats@gmail.com>
|
|
|
|
|
|
| |
[#4119 state:committed]
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
|
|
|
|
| |
Signed-off-by: wycats <wycats@gmail.com>
|
| |
|
| |
|
|
|
|
| |
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
|
| |
|
|
|
|
|
|
|
|
| |
met the default_scope conditions, added test [#3166 status:resolved]
The reload method didn't made use of 'with_exclusive_scope' when reloading the object. This lead to a RecordNotFound exception, in case the object doesn't met the default_scope condition (anymore) - which is obviously a bug. This quick fix makes use of with_exclusive_scope in the reload method as well. See test for full example.
Signed-off-by: José Valim <jose.valim@gmail.com>
|
|
|
|
|
|
| |
initialization [#3218 status:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
destroyed? methods. ActionPack does not care if the resource is new or if it was destroyed, it cares only if it's persisted somewhere or not.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Obviously #key is a too common name to be included
in the AMo interface, #to_key fits better and also
relates nicely to #to_param. Thx wycats, koz and
josevalim for the suggestion.
AR's #to_key implementation now takes customized
primary keys into account and there's a testcase
for that too.
The #to_param AMo lint makes no assumptions on how
the method behaves in the presence of composite
primary keys. It leaves the decision wether to
provide a default, or to raise and thus signal to
the user that implementing this method will need
his special attention, up to the implementers. All
AMo cares about is that #to_param is implemented
and returns nil in case of a new_record?.
The default CompliantObject used in lint_test
provides a naive default implementation that just
joins all key attributes with '-'.
The #to_key default implementation in lint_test's
CompliantObject now returns [id] instead of [1].
This was previously causing the (wrong) tests I
added for AR's #to_key implementation to pass. The
#to_key tests added with this patch should be
better.
The CI failure was caused by my lack of knowledge
about the test:isolated task. The tests for the
record_identifier code in action_controller are
using fake non AR models and I forgot to stub the
#to_key method over there. This issue didn't come
up when running the test task, only test:isolated
revealed it. This patch fixes that.
All tests pass isolated or not, well, apart from
one previously unpended test in action_controller
that is unrelated to my patch.
|