Updated ruby 1.9 hash syntax

This commit is contained in:
Anshul Sharma
2014-02-25 22:12:55 +05:30
parent 4995d3c221
commit dc1b399a8b
98 changed files with 950 additions and 950 deletions

View File

@@ -23,7 +23,7 @@ class DeviseTest < ActiveSupport::TestCase
end
test 'model options can be configured through Devise' do
swap Devise, :allow_unconfirmed_access_for => 113, :pepper => "foo" do
swap Devise, allow_unconfirmed_access_for: 113, pepper: "foo" do
assert_equal 113, Devise.allow_unconfirmed_access_for
assert_equal "foo", Devise.pepper
end
@@ -60,12 +60,12 @@ class DeviseTest < ActiveSupport::TestCase
assert_not defined?(Devise::Models::Coconut)
Devise::ALL.delete(:coconut)
assert_nothing_raised(Exception) { Devise.add_module(:banana, :strategy => :fruits) }
assert_nothing_raised(Exception) { Devise.add_module(:banana, strategy: :fruits) }
assert_equal :fruits, Devise::STRATEGIES[:banana]
Devise::ALL.delete(:banana)
Devise::STRATEGIES.delete(:banana)
assert_nothing_raised(Exception) { Devise.add_module(:kivi, :controller => :fruits) }
assert_nothing_raised(Exception) { Devise.add_module(:kivi, controller: :fruits) }
assert_equal :fruits, Devise::CONTROLLERS[:kivi]
Devise::ALL.delete(:kivi)
Devise::CONTROLLERS.delete(:kivi)