diff options
Diffstat (limited to 'spec/routing/routing_spec.rb')
-rw-r--r-- | spec/routing/routing_spec.rb | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/spec/routing/routing_spec.rb b/spec/routing/routing_spec.rb index af4becd980b..722e687838f 100644 --- a/spec/routing/routing_spec.rb +++ b/spec/routing/routing_spec.rb @@ -32,13 +32,6 @@ RSpec.describe UsersController, "routing" do expect(get("/users/User/snippets")).to route_to('users#snippets', username: 'User') end - # get all the ssh-keys of a user - it "to #get_keys" do - allow_any_instance_of(::Constraints::UserUrlConstrainer).to receive(:matches?).and_return(true) - - expect(get("/User.keys")).to route_to('users#ssh_keys', username: 'User') - end - it "to #calendar" do expect(get("/users/User/calendar")).to route_to('users#calendar', username: 'User') end @@ -193,6 +186,12 @@ RSpec.describe Profiles::KeysController, "routing" do it "to #destroy" do expect(delete("/profile/keys/1")).to route_to('profiles/keys#destroy', id: '1') end + + it "to #get_keys" do + allow_any_instance_of(::Constraints::UserUrlConstrainer).to receive(:matches?).and_return(true) + + expect(get("/foo.keys")).to route_to('profiles/keys#get_keys', username: 'foo') + end end # emails GET /emails(.:format) emails#index |