1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Corrected some typos and American vs. Queen's English issues

This commit is contained in:
Lee Reilly 2011-05-29 12:40:24 -07:00
parent 18b153d15d
commit 4f234bfd79
6 changed files with 10 additions and 10 deletions

View file

@ -60,11 +60,11 @@ module ActionDispatch
assert_response(:redirect, message)
return true if options == @response.location
redirected_to_after_normalisation = normalize_argument_to_redirection(@response.location)
options_after_normalisation = normalize_argument_to_redirection(options)
redirected_to_after_normalization = normalize_argument_to_redirection(@response.location)
options_after_normalization = normalize_argument_to_redirection(options)
if redirected_to_after_normalisation != options_after_normalisation
flunk "Expected response to be a redirect to <#{options_after_normalisation}> but was a redirect to <#{redirected_to_after_normalisation}>"
if redirected_to_after_normalization != options_after_normalization
flunk "Expected response to be a redirect to <#{options_after_normalization}> but was a redirect to <#{redirected_to_after_normalization}>"
end
end

View file

@ -40,7 +40,7 @@ module Dispatching
class ContainedEmptyController < ActionController::Base ; end
class ContainedSubEmptyController < ContainedEmptyController ; end
class ContainedNonDefaultPathController < ActionController::Base
def self.controller_path; "i_am_extremly_not_default"; end
def self.controller_path; "i_am_extremely_not_default"; end
end
end
@ -89,7 +89,7 @@ module Dispatching
end
test "namespaced non-default controller path" do
assert_equal 'i_am_extremly_not_default', Submodule::ContainedNonDefaultPathController.controller_path
assert_equal 'i_am_extremely_not_default', Submodule::ContainedNonDefaultPathController.controller_path
assert_equal Submodule::ContainedNonDefaultPathController.controller_path, Submodule::ContainedNonDefaultPathController.new.controller_path
end

View file

@ -860,7 +860,7 @@ module ActiveRecord
# the inverse of each other and the inverse of the +dungeon+ association on +EvilWizard+
# is the +evil_wizard+ association on +Dungeon+ (and vice-versa). By default,
# Active Record doesn't know anything about these inverse relationships and so no object
# loading optimisation is possible. For example:
# loading optimization is possible. For example:
#
# d = Dungeon.first
# t = d.traps.first

View file

@ -17,7 +17,7 @@ module ActiveRecord
# posts.each {|p| puts p.name } # Fires "select * from posts" and loads post objects
#
# fruits = Fruit.scoped
# fruits = fruits.where(:colour => 'red') if options[:red_only]
# fruits = fruits.where(:color => 'red') if options[:red_only]
# fruits = fruits.limit(10) if limited?
#
# Anonymous \scopes tend to be useful when procedurally generating complex

View file

@ -106,7 +106,7 @@ HEADER
spec = {}
spec[:name] = column.name.inspect
# AR has an optimisation which handles zero-scale decimals as integers. This
# AR has an optimization which handles zero-scale decimals as integers. This
# code ensures that the dumper still dumps the column as a decimal.
spec[:type] = if column.type == :integer && [/^numeric/, /^decimal/].any? { |e| e.match(column.sql_type) }
'decimal'

View file

@ -283,7 +283,7 @@ module ActiveResource
# attribute 'name', :string
#
# # or use the convenience methods and pass >=1 attribute names
# string 'eye_colour', 'hair_colour'
# string 'eye_color', 'hair_color'
# integer 'age'
# float 'height', 'weight'
#