diff options
Diffstat (limited to 'activesupport/lib/active_support/core_ext')
20 files changed, 51 insertions, 54 deletions
diff --git a/activesupport/lib/active_support/core_ext/array.rb b/activesupport/lib/active_support/core_ext/array.rb index 1d18900bab..4c973488a5 100644 --- a/activesupport/lib/active_support/core_ext/array.rb +++ b/activesupport/lib/active_support/core_ext/array.rb @@ -1,7 +1,7 @@ -require File.dirname(__FILE__) + '/array/conversions' -require File.dirname(__FILE__) + '/array/extract_options' -require File.dirname(__FILE__) + '/array/grouping' -require File.dirname(__FILE__) + '/array/random_access' +require 'active_support/core_ext/array/conversions' +require 'active_support/core_ext/array/extract_options' +require 'active_support/core_ext/array/grouping' +require 'active_support/core_ext/array/random_access' class Array #:nodoc: include ActiveSupport::CoreExtensions::Array::Conversions diff --git a/activesupport/lib/active_support/core_ext/bigdecimal.rb b/activesupport/lib/active_support/core_ext/bigdecimal.rb index 436b3e000f..b442ae9655 100644 --- a/activesupport/lib/active_support/core_ext/bigdecimal.rb +++ b/activesupport/lib/active_support/core_ext/bigdecimal.rb @@ -1,3 +1,2 @@ require 'bigdecimal' - -require File.dirname(__FILE__) + '/bigdecimal/formatting.rb' +require 'active_support/core_ext/bigdecimal/conversions' diff --git a/activesupport/lib/active_support/core_ext/bigdecimal/formatting.rb b/activesupport/lib/active_support/core_ext/bigdecimal/conversions.rb index d86adbea6c..dcdb08aea0 100644 --- a/activesupport/lib/active_support/core_ext/bigdecimal/formatting.rb +++ b/activesupport/lib/active_support/core_ext/bigdecimal/conversions.rb @@ -1,7 +1,6 @@ class BigDecimal #:nodoc: - alias :_original_to_s :to_s def to_s(format="F") _original_to_s(format) end -end
\ No newline at end of file +end diff --git a/activesupport/lib/active_support/core_ext/cgi.rb b/activesupport/lib/active_support/core_ext/cgi.rb index 072a7c99d2..db90e5c745 100644 --- a/activesupport/lib/active_support/core_ext/cgi.rb +++ b/activesupport/lib/active_support/core_ext/cgi.rb @@ -1,5 +1,5 @@ -require File.dirname(__FILE__) + '/cgi/escape_skipping_slashes' +require 'active_support/core_ext/cgi/escape_skipping_slashes' class CGI #:nodoc: - extend(ActiveSupport::CoreExtensions::CGI::EscapeSkippingSlashes) + extend ActiveSupport::CoreExtensions::CGI::EscapeSkippingSlashes end diff --git a/activesupport/lib/active_support/core_ext/class.rb b/activesupport/lib/active_support/core_ext/class.rb index 7bacdb3903..83eb8135f4 100644 --- a/activesupport/lib/active_support/core_ext/class.rb +++ b/activesupport/lib/active_support/core_ext/class.rb @@ -1,3 +1,3 @@ -require File.dirname(__FILE__) + '/class/attribute_accessors' -require File.dirname(__FILE__) + '/class/inheritable_attributes' -require File.dirname(__FILE__) + '/class/removal'
\ No newline at end of file +require 'active_support/core_ext/class/attribute_accessors' +require 'active_support/core_ext/class/inheritable_attributes' +require 'active_support/core_ext/class/removal' diff --git a/activesupport/lib/active_support/core_ext/date.rb b/activesupport/lib/active_support/core_ext/date.rb index 9d9051dfbe..3f56c560b6 100644 --- a/activesupport/lib/active_support/core_ext/date.rb +++ b/activesupport/lib/active_support/core_ext/date.rb @@ -1,7 +1,7 @@ require 'date' -require File.dirname(__FILE__) + '/date/behavior' -require File.dirname(__FILE__) + '/date/calculations' -require File.dirname(__FILE__) + '/date/conversions' +require 'active_support/core_ext/date/behavior' +require 'active_support/core_ext/date/calculations' +require 'active_support/core_ext/date/conversions' class Date#:nodoc: include ActiveSupport::CoreExtensions::Date::Behavior diff --git a/activesupport/lib/active_support/core_ext/date_time.rb b/activesupport/lib/active_support/core_ext/date_time.rb index 7ce1b78090..1d711de70b 100644 --- a/activesupport/lib/active_support/core_ext/date_time.rb +++ b/activesupport/lib/active_support/core_ext/date_time.rb @@ -1,7 +1,7 @@ require 'date' -require "#{File.dirname(__FILE__)}/time/behavior" -require "#{File.dirname(__FILE__)}/date_time/calculations" -require "#{File.dirname(__FILE__)}/date_time/conversions" +require 'active_support/core_ext/time/behavior' +require 'active_support/core_ext/date_time/calculations' +require 'active_support/core_ext/date_time/conversions' class DateTime include ActiveSupport::CoreExtensions::Time::Behavior diff --git a/activesupport/lib/active_support/core_ext/float.rb b/activesupport/lib/active_support/core_ext/float.rb index ac5d5a47e6..86862b7150 100644 --- a/activesupport/lib/active_support/core_ext/float.rb +++ b/activesupport/lib/active_support/core_ext/float.rb @@ -1,4 +1,4 @@ -require File.dirname(__FILE__) + '/float/rounding' +require 'active_support/core_ext/float/rounding' class Float #:nodoc: include ActiveSupport::CoreExtensions::Float::Rounding diff --git a/activesupport/lib/active_support/core_ext/hash.rb b/activesupport/lib/active_support/core_ext/hash.rb index b805d2da62..6cbd9dd378 100644 --- a/activesupport/lib/active_support/core_ext/hash.rb +++ b/activesupport/lib/active_support/core_ext/hash.rb @@ -1,5 +1,5 @@ %w(keys indifferent_access reverse_merge conversions diff slice except).each do |ext| - require "#{File.dirname(__FILE__)}/hash/#{ext}" + require "active_support/core_ext/hash/#{ext}" end class Hash #:nodoc: diff --git a/activesupport/lib/active_support/core_ext/integer.rb b/activesupport/lib/active_support/core_ext/integer.rb index 9346b88fd5..d1e6d76acb 100644 --- a/activesupport/lib/active_support/core_ext/integer.rb +++ b/activesupport/lib/active_support/core_ext/integer.rb @@ -1,5 +1,5 @@ -require File.dirname(__FILE__) + '/integer/even_odd' -require File.dirname(__FILE__) + '/integer/inflections' +require 'active_support/core_ext/integer/even_odd' +require 'active_support/core_ext/integer/inflections' class Integer #:nodoc: include ActiveSupport::CoreExtensions::Integer::EvenOdd diff --git a/activesupport/lib/active_support/core_ext/kernel.rb b/activesupport/lib/active_support/core_ext/kernel.rb index 6475be7efa..1922d804bf 100644 --- a/activesupport/lib/active_support/core_ext/kernel.rb +++ b/activesupport/lib/active_support/core_ext/kernel.rb @@ -1,5 +1,5 @@ -require File.dirname(__FILE__) + '/kernel/daemonizing' -require File.dirname(__FILE__) + '/kernel/reporting' -require File.dirname(__FILE__) + '/kernel/agnostics' -require File.dirname(__FILE__) + '/kernel/requires' -require File.dirname(__FILE__) + '/kernel/debugger' +require 'active_support/core_ext/kernel/daemonizing' +require 'active_support/core_ext/kernel/reporting' +require 'active_support/core_ext/kernel/agnostics' +require 'active_support/core_ext/kernel/requires' +require 'active_support/core_ext/kernel/debugger' diff --git a/activesupport/lib/active_support/core_ext/module.rb b/activesupport/lib/active_support/core_ext/module.rb index 26c9bdf778..da8d5b3762 100644 --- a/activesupport/lib/active_support/core_ext/module.rb +++ b/activesupport/lib/active_support/core_ext/module.rb @@ -1,8 +1,8 @@ -require File.dirname(__FILE__) + '/module/inclusion' -require File.dirname(__FILE__) + '/module/attribute_accessors' -require File.dirname(__FILE__) + '/module/attr_internal' -require File.dirname(__FILE__) + '/module/attr_accessor_with_default' -require File.dirname(__FILE__) + '/module/delegation' -require File.dirname(__FILE__) + '/module/introspection' -require File.dirname(__FILE__) + '/module/loading' -require File.dirname(__FILE__) + '/module/aliasing' +require 'active_support/core_ext/module/inclusion' +require 'active_support/core_ext/module/attribute_accessors' +require 'active_support/core_ext/module/attr_internal' +require 'active_support/core_ext/module/attr_accessor_with_default' +require 'active_support/core_ext/module/delegation' +require 'active_support/core_ext/module/introspection' +require 'active_support/core_ext/module/loading' +require 'active_support/core_ext/module/aliasing' diff --git a/activesupport/lib/active_support/core_ext/numeric.rb b/activesupport/lib/active_support/core_ext/numeric.rb index 88fead7aa4..59da205b3d 100644 --- a/activesupport/lib/active_support/core_ext/numeric.rb +++ b/activesupport/lib/active_support/core_ext/numeric.rb @@ -1,5 +1,5 @@ -require File.dirname(__FILE__) + '/numeric/time' -require File.dirname(__FILE__) + '/numeric/bytes' +require 'active_support/core_ext/numeric/time' +require 'active_support/core_ext/numeric/bytes' class Numeric #:nodoc: include ActiveSupport::CoreExtensions::Numeric::Time diff --git a/activesupport/lib/active_support/core_ext/object.rb b/activesupport/lib/active_support/core_ext/object.rb index 57238f38f5..3b055d3185 100644 --- a/activesupport/lib/active_support/core_ext/object.rb +++ b/activesupport/lib/active_support/core_ext/object.rb @@ -1,3 +1,3 @@ -require File.dirname(__FILE__) + '/object/extending' -require File.dirname(__FILE__) + '/object/instance_variables' -require File.dirname(__FILE__) + '/object/misc' +require 'active_support/core_ext/object/extending' +require 'active_support/core_ext/object/instance_variables' +require 'active_support/core_ext/object/misc' diff --git a/activesupport/lib/active_support/core_ext/pathname.rb b/activesupport/lib/active_support/core_ext/pathname.rb index 9e78c273d9..4c5318ee63 100644 --- a/activesupport/lib/active_support/core_ext/pathname.rb +++ b/activesupport/lib/active_support/core_ext/pathname.rb @@ -1,5 +1,5 @@ require 'pathname' -require File.dirname(__FILE__) + '/pathname/clean_within' +require 'active_support/core_ext/pathname/clean_within' class Pathname#:nodoc: extend ActiveSupport::CoreExtensions::Pathname::CleanWithin diff --git a/activesupport/lib/active_support/core_ext/range.rb b/activesupport/lib/active_support/core_ext/range.rb index ca77511521..ee7868a2f8 100644 --- a/activesupport/lib/active_support/core_ext/range.rb +++ b/activesupport/lib/active_support/core_ext/range.rb @@ -1,4 +1,4 @@ -require File.dirname(__FILE__) + '/range/conversions' +require 'active_support/core_ext/range/conversions' class Range #:nodoc: include ActiveSupport::CoreExtensions::Range::Conversions diff --git a/activesupport/lib/active_support/core_ext/string.rb b/activesupport/lib/active_support/core_ext/string.rb index ef2f334fe2..724b2af2ee 100644 --- a/activesupport/lib/active_support/core_ext/string.rb +++ b/activesupport/lib/active_support/core_ext/string.rb @@ -1,9 +1,9 @@ -require File.dirname(__FILE__) + '/string/inflections' -require File.dirname(__FILE__) + '/string/conversions' -require File.dirname(__FILE__) + '/string/access' -require File.dirname(__FILE__) + '/string/starts_ends_with' -require File.dirname(__FILE__) + '/string/iterators' unless 'test'.respond_to?(:each_char) -require File.dirname(__FILE__) + '/string/unicode' +require 'active_support/core_ext/string/inflections' +require 'active_support/core_ext/string/conversions' +require 'active_support/core_ext/string/access' +require 'active_support/core_ext/string/starts_ends_with' +require 'active_support/core_ext/string/iterators' unless 'test'.respond_to?(:each_char) +require 'active_support/core_ext/string/unicode' class String #:nodoc: include ActiveSupport::CoreExtensions::String::Access diff --git a/activesupport/lib/active_support/core_ext/test.rb b/activesupport/lib/active_support/core_ext/test.rb index 193599b8dc..c0b19bdc58 100644 --- a/activesupport/lib/active_support/core_ext/test.rb +++ b/activesupport/lib/active_support/core_ext/test.rb @@ -1,2 +1 @@ -require File.dirname(__FILE__) + '/test/difference' - +require 'active_support/core_ext/test/unit/assertions' diff --git a/activesupport/lib/active_support/core_ext/test/difference.rb b/activesupport/lib/active_support/core_ext/test/unit/assertions.rb index 2ae4b7d6d1..2ae4b7d6d1 100644 --- a/activesupport/lib/active_support/core_ext/test/difference.rb +++ b/activesupport/lib/active_support/core_ext/test/unit/assertions.rb diff --git a/activesupport/lib/active_support/core_ext/time.rb b/activesupport/lib/active_support/core_ext/time.rb index a9e6a4385c..d87c4ec65a 100644 --- a/activesupport/lib/active_support/core_ext/time.rb +++ b/activesupport/lib/active_support/core_ext/time.rb @@ -8,9 +8,9 @@ class Time end end -require File.dirname(__FILE__) + '/time/behavior' -require File.dirname(__FILE__) + '/time/calculations' -require File.dirname(__FILE__) + '/time/conversions' +require 'active_support/core_ext/time/behavior' +require 'active_support/core_ext/time/calculations' +require 'active_support/core_ext/time/conversions' class Time#:nodoc: include ActiveSupport::CoreExtensions::Time::Behavior |