Commit 95295608 authored by charlie ablett's avatar charlie ablett

Merge branch 'dz-scope-profile-routes-by-default' into 'master'

Use scoped profile routes by default

See merge request gitlab-org/gitlab!45307
parents 8272c037 e9d57390
......@@ -180,6 +180,7 @@ Rails.application.routes.draw do
get 'jwks' => 'doorkeeper/openid_connect/discovery#keys'
draw :snippets
draw :profile
# Product analytics collector
match '/collector/i', to: ProductAnalytics::CollectorApp.new, via: :all
......@@ -266,7 +267,6 @@ Rails.application.routes.draw do
draw :uploads
draw :explore
draw :admin
draw :profile
draw :dashboard
draw :user
draw :project
......@@ -274,13 +274,6 @@ Rails.application.routes.draw do
# Issue https://gitlab.com/gitlab-org/gitlab/-/issues/210024
scope as: 'deprecated' do
draw :snippets
end
# Serve profile routes under /-/ scope.
# To ensure an old unscoped routing is used for the UI we need to
# add prefix 'as' to the scope routing and place it below original routing.
# Issue https://gitlab.com/gitlab-org/gitlab/-/issues/210024
scope '-', as: :scoped do
draw :profile
end
......
......@@ -99,7 +99,7 @@ RSpec.describe DashboardOperationsProjectEntity do
let(:user) { build(:user, :admin) }
it 'shows the profile upgrade path' do
expect(subject[:upgrade_path]).to eq '/profile/billings'
expect(subject[:upgrade_path]).to eq '/-/profile/billings'
end
end
......
......@@ -33,7 +33,7 @@ RSpec.describe 'Profile > Account', :js do
end
it 'allows the user to disconnect when there is an existing identity' do
expect(page).to have_link('Disconnect Twitter', href: '/profile/account/unlink?provider=twitter')
expect(page).to have_link('Disconnect Twitter', href: '/-/profile/account/unlink?provider=twitter')
end
it 'shows active for a provider that is not allowed to unlink' do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment