aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test/dependencies_test.rb
Commit message (Collapse)AuthorAgeFilesLines
* Simplify load and require testsSam Umbach2011-12-031-4/+4
| | | | - These tests don't use autoloading so there's no need to add anything to autoload_paths
* Test that require and load raise LoadError if file not foundSam Umbach2011-12-031-0/+16
|
* Test return value of ActiveSupport::Dependencies::Loadable#loadSam Umbach2011-12-031-0/+16
|
* Test return value of ActiveSupport::Dependencies::Loadable#requireSam Umbach2011-12-031-0/+47
| | | | | - Add tests to protect from regressions in require's return value behavior - See a10606c490471d8e1483acb3b31d7f2d51e9ebbe (require needs to return true or false) for the original bug fix
* Fix autoload_once_paths when using Pathnames & ruby 1.9Jonathan del Strother2011-08-241-0/+18
| | | | | | | Under ruby 1.9.2 - "/var/log".starts_with?(Pathname.new("/var")) # => false so setting config.autoload_once_paths with Pathnames would not work
* Removing extra requires from the test. Already loaded in abstract_unit.Arun Agrawal2011-07-311-1/+0
|
* Raise NameError instead of ArgumentError in ActiveSupport::DependenciesAndrew White2011-06-011-1/+1
| | | | | | | | ActiveSupport::Dependencies now raises NameError if it finds an existing constant in load_missing_constant. This better reflects the nature of the error which is usually caused by calling constantize on a nested constant. Closes #1423
* Fix failing tests.José Valim2011-05-221-0/+2
|
* adding deprecation noticies to deprecated class cache methodsAaron Patterson2011-03-021-4/+4
|
* adding backwards compat for class cache references. <3<3Aaron Patterson2011-03-021-3/+3
|
* refactor Reference to a ClassCache object, fix lazy lookup in Middleware so ↵Aaron Patterson2011-03-011-3/+3
| | | | that anonymous classes are supported
* Add before_remove_const callback to ↵Andrew White2010-09-011-0/+11
| | | | | | ActiveSupport::Dependencies.remove_unloadable_constants! Signed-off-by: Xavier Noria <fxn@hashref.com>
* Sadly, this segv's in 1.8 :(wycats2010-08-171-5/+5
|
* This is for making sure const_missing is triggered without warningsSantiago Pastorino2010-07-261-4/+6
|
* Fix a bug where requires inside of autoloads were being added to the ↵wycats2010-07-261-0/+49
| | | | autoloaded_constants list, causing mayhem. [#5165 state:resolved]
* Removes unused varsSantiago Pastorino2010-07-241-2/+0
| | | | Signed-off-by: José Valim <jose.valim@gmail.com>
* Makes restore previosly saved warnings_on_first_load value and avoid warningSantiago Pastorino2010-07-241-0/+1
| | | | Signed-off-by: José Valim <jose.valim@gmail.com>
* renames load_(once_)paths to autoload_(once_)paths in dependencies and configXavier Noria2010-06-241-18/+18
|
* ActiveSupport::Dependencies.constantize shortcut for caching named constant ↵Jeremy Kemper2010-06-051-0/+6
| | | | lookups
* Optimize LookupContextwycats2010-06-041-0/+15
|
* refactor evals and adds some __FILE__ and __LINE__Santiago Pastorino2010-05-201-1/+1
| | | | Signed-off-by: José Valim <jose.valim@gmail.com>
* Make dependencies_test pass running standalone [#4215 state:resolved]Santiago Pastorino and Sebastian Martinez2010-03-181-1/+1
| | | | Signed-off-by: wycats <wycats@gmail.com>
* Simplify dependencies.rb some. Remove alias of Kernel::Foo to Object::Foo as ↵Yehuda Katz2010-02-141-11/+6
| | | | it was not used and breaks Ruby semantics.
* Since require_dependency cannot be cleared, remove the dependenciesYehuda Katz2010-02-101-0/+5
|
* removes Module#as_load_path, which is no longer usedXavier Noria2010-02-071-5/+0
|
* Symbol#to_proc is not needed for Ruby >= 1.8.7Xavier Noria2009-11-091-1/+0
|
* Fix failing dependencies test relying on . being in LOAD_PATHJeremy Kemper2009-08-091-2/+4
|
* Extract repetitive methodJeremy Kemper2009-08-091-33/+37
|
* Uses &:fooJeremy Kemper2009-08-091-0/+1
|
* Fix dependencies revealed by testing in isolationJeremy Kemper2009-04-221-0/+2
|
* Opt in to DependenciesJeremy Kemper2009-04-221-0/+1
|
* Ruby 1.9 compat: rename deprecated assert_raises to assert_raise.Jeremy Kemper2009-03-081-11/+11
| | | | [#1617 state:resolved]
* Only track new constant definitions when we're reloading dependenciesJeremy Kemper2008-11-101-5/+5
|
* Remove stuff that was deprecated in 2-1-stablePratik Naik2008-10-211-1/+0
|
* Get rid of 'Object#send!'. It was originally added because it's in Ruby 1.9, ↵Jeremy Kemper2008-08-311-9/+9
| | | | | | | | | | but it has since been removed from 1.9. Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net> Conflicts: actionpack/test/controller/layout_test.rb
* Added config.dependency_loading to enable or disable the dependency loader ↵Joshua Peek2008-07-241-0/+12
| | | | after initialization
* Namespace Inflector, Dependencies, OrderedOptions, and TimeZone under ↵Joshua Peek2008-06-031-120/+120
| | | | ActiveSupport [#238 state:resolved]
* Fixed Dependencies so load errors are not masked behind a 'Expected x.rb to ↵Tom Ward2008-05-311-6/+14
| | | | | | define X' message when mechanism is not set to :load [#87 state:resolved] Signed-off-by: Joshua Peek <josh@joshpeek.com>
* Fix Dependencies watch_frames collection. [#24 state:resolved]Tom Ward2008-05-201-0/+6
| | | | | | | | | | Previously, the code collecting watch_frames could fail leaving watch_frames defined but nil. The cleanup code checks watch_frames is defined, but not that it holds a value, raising an undefined method on NilClass error rather than the original cause. This can make debugging the underlying cause a total pain. Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* remove some more absolute requiresJeremy Kemper2008-01-051-5/+5
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8567 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* 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
* Dependencies Ruby 1.9 compatJeremy Kemper2007-09-271-31/+30
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7660 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Update Dependencies to ignore constants inherited from ancestors. Closes #6951.Nicholas Seckar2007-03-141-0/+11
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6426 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* tighten test_load_once_paths_should_behave_when_recursively_loadingJeremy Kemper2007-01-011-2/+3
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5816 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Check for nil name also. Closes #6561.Jeremy Kemper2006-12-311-1/+6
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5814 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix Dependencies.autoloaded? to ignore anonymous modules. Closes #6561.Nicholas Seckar2006-12-311-1/+3
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5811 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Checkin failing test case related to load once pathsNicholas Seckar2006-12-241-0/+28
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5781 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix remove_constant to correctly handle constant names of the form ↵Nicholas Seckar2006-12-091-0/+11
| | | | | | "::A::...". References #6720. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5710 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Test autoloading nested subclass of parent.Jeremy Kemper2006-11-161-0/+9
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5541 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Update dependencies to delete partially loaded constants.Nicholas Seckar2006-11-071-2/+5
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5464 5ecf4fe2-1ee6-0310-87b1-e25e094e27de