aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test/core_ext/module_test.rb
Commit message (Collapse)AuthorAgeFilesLines
* Remove unused line in test setup.Ben Orenstein2011-02-171-1/+0
| | | | | | [#6442 state:committed] Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
* Remove unused code.Ben Orenstein2011-02-161-3/+0
| | | | | | [#6437 state:committed] Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
* delegate method should treat :prefix => false same as :prefix => nilNeeraj Singh2010-09-011-0/+13
| | | | | | [#5375 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* Removes unused varsSantiago Pastorino2010-07-241-1/+1
| | | | Signed-off-by: José Valim <jose.valim@gmail.com>
* Final iteration of use better testing methodsNeeraj Singh2010-05-191-5/+5
| | | | | | [#4652 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* Singleton classes returns parent's methods with instance_methods(false) and ↵José Valim2010-03-191-0/+14
| | | | this makes remove_method in Module#delegate fail. Add a test case and fix the bug.
* Fix test ordering bug related to introducing masked Name classYehuda Katz2010-02-191-14/+6
|
* removes Module#as_load_path, which is no longer usedXavier Noria2010-02-071-5/+0
|
* removes Module#included_in_classes, which is no longer usedXavier Noria2010-02-071-7/+0
|
* Allow delegating to nil, because the method might actually exist on itBryan Helmkamp2009-08-101-1/+12
|
* Friendlier runtime exception if delegatee is nilJeremy Kemper2009-06-181-1/+1
|
* Explicit test dependenciesJeremy Kemper2009-03-281-0/+1
|
* Ruby 1.9 compat: rename deprecated assert_raises to assert_raise.Jeremy Kemper2009-03-081-5/+5
| | | | [#1617 state:resolved]
* Add :allow_nil option to delegate [#1127 state:resolved]Sergio Gil2008-12-211-0/+27
| | | | Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* Ensure only delegations to methods can have an automatic prefix. [#1235 ↵Daniel Schierbeck2008-11-211-0/+11
| | | | | | state:resolved] Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* Moved test object instantiation to a setup method.Daniel Schierbeck2008-10-191-9/+9
| | | | Signed-off-by: Michael Koziarski <michael@koziarski.com>
* Made the :prefix option on Module#delegate accept a custom prefix.Daniel Schierbeck2008-10-191-0/+9
| | | | Signed-off-by: Michael Koziarski <michael@koziarski.com>
* Added :prefix option to Module#delegate.Daniel Schierbeck2008-10-191-0/+12
| | | | Signed-off-by: Michael Koziarski <michael@koziarski.com>
* require abstract_unit directly since test is in load pathJeremy Kemper2008-01-051-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8563 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Prefer class_eval with block to many sends for Ruby 1.9 compatJeremy Kemper2007-09-271-53/+72
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7652 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* alias_method_chain preserves the original method's visibility. Closes #7854.Jeremy Kemper2007-03-181-0/+45
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6441 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Update Dependencies to ignore constants inherited from ancestors. Closes #6951.Nicholas Seckar2007-03-141-0/+8
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6426 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* alias_method_chain yields method target and punctuation to simplify wrapper ↵Jeremy Kemper2006-09-151-0/+15
| | | | | | method definition. Used by the deprecate module method. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5113 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* alias_method_chain works with accessor= methods also. Closes #6153.Jeremy Kemper2006-09-121-9/+22
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5091 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* More tests for alias_method_chain with feature and method punctuation. ↵Jeremy Kemper2006-09-031-0/+15
| | | | | | Closes #4954. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4920 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added Module#alias_attribute [Jamis/DHH]David Heinemeier Hansson2006-08-031-1/+0
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4653 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* r4487@asus: jeremy | 2006-04-29 12:21:39 -0700Jeremy Kemper2006-07-081-12/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Check whether @flash is defined? for warnings-safety. r4488@asus: jeremy | 2006-04-29 12:23:15 -0700 Check whether @flash is defined? for warnings-safety. Obviates nil? check. r4489@asus: jeremy | 2006-04-29 12:45:18 -0700 Check whether @session is defined? for warnings-safety. r4490@asus: jeremy | 2006-04-29 12:50:41 -0700 Check whether @rendering_runtime is defined? for warnings-safety. r4491@asus: jeremy | 2006-04-29 12:55:01 -0700 Check whether @_cycles is defined? for warnings-safety. r4492@asus: jeremy | 2006-04-29 12:59:19 -0700 Check whether instance variables are defined? for warnings-safety. r4493@asus: jeremy | 2006-04-29 13:14:09 -0700 Add nil @template to PrototypeHelperTest to suppress unitialized instance variable warning. r4494@asus: jeremy | 2006-04-29 13:31:34 -0700 Check whether @auto_index defined? for warnings-safety. r4495@asus: jeremy | 2006-04-29 13:32:24 -0700 Wrap content_columns redefinitions with silence_warnings. r4496@asus: jeremy | 2006-04-29 13:35:28 -0700 Wrap more redefinitions with silence_warnings. r4829@asus: jeremy | 2006-07-08 10:59:20 -0700 abstract unit, fix warnings r4830@asus: jeremy | 2006-07-08 11:06:12 -0700 Use parens to silence warning. r4831@asus: jeremy | 2006-07-08 11:06:48 -0700 Use parens to silence warning. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4595 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed that Module#alias_method_chain should work with both foo? foo! and foo ↵David Heinemeier Hansson2006-06-031-6/+28
| | | | | | at the same time (closes #4954) [anna@wota.jp] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4429 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* fix test warningsJeremy Kemper2006-05-311-2/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4386 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Strip out punctuation on predicates or bang methods being aliased with ↵Marcel Molina2006-04-291-1/+59
| | | | | | alias_method_chain since target?_without_feature is not a valid method name. Add tests for Module#alias_method_chain. [Marcel Molina Jr.] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4311 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Dependencies cleanup. Fixes #4221.Nicholas Seckar2006-03-271-0/+16
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4060 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added delegation support to Module that allows multiple delegations at once ↵David Heinemeier Hansson2006-02-041-0/+48
| | | | | | (unlike Forwardable in the stdlib) [DHH] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3535 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Further improvements to reloading codeNicholas Seckar2006-02-021-14/+0
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3519 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added reusable reloading support through the inclusion of the Relodable ↵David Heinemeier Hansson2006-01-291-0/+51
module that all subclasses of ActiveRecord::Base, ActiveRecord::Observer, ActiveController::Base, and ActionMailer::Base automatically gets [DHH]. Added auto-loading support for classes in modules, so Conductor::Migration will look for conductor/migration.rb and Conductor::Database::Settings will look for conductor/database/settings.rb [Nicholas Seckar]. Refactored extensions to module, class, and object in active support [DHH] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3493 5ecf4fe2-1ee6-0310-87b1-e25e094e27de