Fully embrace Ruby 1.9 hash syntax

Didn't bother with files in db/, config/, or features/
This commit is contained in:
Robert Speicher 2012-08-10 18:07:50 -04:00
parent 1413c23c50
commit 7754189187
257 changed files with 1449 additions and 1449 deletions

View file

@ -22,10 +22,10 @@ describe "Admin::Users" do
before do
@password = "123ABC"
visit new_admin_user_path
fill_in "user_name", :with => "Big Bang"
fill_in "user_email", :with => "bigbang@mail.com"
fill_in "user_password", :with => @password
fill_in "user_password_confirmation", :with => @password
fill_in "user_name", with: "Big Bang"
fill_in "user_email", with: "bigbang@mail.com"
fill_in "user_password", with: @password
fill_in "user_password_confirmation", with: @password
end
it "should create new user" do
@ -40,7 +40,7 @@ describe "Admin::Users" do
end
it "should call send mail" do
Notify.should_receive(:new_user_email).and_return(stub(:deliver => true))
Notify.should_receive(:new_user_email).and_return(stub(deliver: true))
User.observers.enable :user_observer do
click_button "Save"
@ -88,8 +88,8 @@ describe "Admin::Users" do
describe "Update user" do
before do
fill_in "user_name", :with => "Big Bang"
fill_in "user_email", :with => "bigbang@mail.com"
fill_in "user_name", with: "Big Bang"
fill_in "user_email", with: "bigbang@mail.com"
check "user_admin"
click_button "Save"
end
@ -114,7 +114,7 @@ describe "Admin::Users" do
end
it "should create new user" do
select @new_project.name, :from => "project_ids"
select @new_project.name, from: "project_ids"
expect { click_button "Add" }.to change { UsersProject.count }.by(1)
page.should have_content @new_project.name
current_path.should == admin_user_path(@user)