mirror of
https://github.com/Freika/dawarich.git
synced 2026-01-11 09:41:40 -05:00
Fix redirect after creating a user in spec
This commit is contained in:
parent
b97b30c88a
commit
abf46a7436
2 changed files with 2 additions and 1 deletions
|
|
@ -1,6 +1,7 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
class Settings::UsersController < ApplicationController
|
||||
before_action :authenticate_user!
|
||||
before_action :authenticate_admin!
|
||||
|
||||
def index
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ RSpec.describe '/settings/users', type: :request do
|
|||
it 'redirects to the created settings_user' do
|
||||
post settings_users_url, params: { user: valid_attributes }
|
||||
|
||||
expect(response).to redirect_to(settings_url)
|
||||
expect(response).to redirect_to(settings_users_url)
|
||||
expect(flash[:notice]).to eq("User was successfully created, email is #{valid_attributes[:email]}, password is \"password\".")
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in a new issue