diff --git a/config/routes.rb b/config/routes.rb index 47fdf2df4..d1295c2cd 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -171,7 +171,7 @@ Rails.application.routes.draw do get 'logout' => 'users/sessions#logout' end - get 'password_complexity' => 'password_complexity#show', as: 'show_password_complexity' + post 'password_complexity' => 'password_complexity#show', as: 'show_password_complexity' get 'check_email' => 'email_checker#show', as: 'show_email_suggestions' resources :targeted_user_links, only: [:show] diff --git a/spec/controllers/password_complexity_controller_spec.rb b/spec/controllers/password_complexity_controller_spec.rb index 7f8696757..4733f1edc 100644 --- a/spec/controllers/password_complexity_controller_spec.rb +++ b/spec/controllers/password_complexity_controller_spec.rb @@ -6,7 +6,7 @@ describe PasswordComplexityController, type: :controller do { user: { password: 'motDePasseTropFacile' } } end - subject { get :show, format: :turbo_stream, params: params } + subject { post :show, format: :turbo_stream, params: params } it 'computes a password score' do subject