Skip to content

Instantly share code, notes, and snippets.

@erez-rabih
Created July 20, 2012 08:32
Show Gist options
  • Save erez-rabih/3149627 to your computer and use it in GitHub Desktop.
Save erez-rabih/3149627 to your computer and use it in GitHub Desktop.
#routes.rb
resources :users
#spec.rb
before do
@user = User.new(:name => "fakename")
@user.save
end
context "clicking My Account link" do
before do
click_link("My Account")
end
describe "current_path" do
it "should be edit_user_path" do
current_path.should eq(edit_user_path(@user))
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment