Use keyword arguments in tests
Raisl 5.1 removes support for non-keyword arguments in `#process`, `#get`, `#post`, `#patch`, `#put`, `#delete`, and `#head` for the `ActionDispatch::IntegrationTest` and `ActionController::TestCase` classes. This means we have to add `params` everywhere in the controller tests.
This commit is contained in:
parent
b8013661a2
commit
d1180e2767
35 changed files with 975 additions and 364 deletions
|
|
@ -11,7 +11,7 @@ describe ConfirmationsController do
|
|||
|
||||
context 'user is not signed in' do
|
||||
it 'confirms and signs in user' do
|
||||
get :show, confirmation_token: user.confirmation_token
|
||||
get :show, params: { confirmation_token: user.confirmation_token }
|
||||
user.reload
|
||||
expect(user.confirmed?).to eq true
|
||||
expect(controller.current_user).to eq user
|
||||
|
|
@ -22,7 +22,7 @@ describe ConfirmationsController do
|
|||
before { sign_in user }
|
||||
|
||||
it 'confirms user' do
|
||||
get :show, confirmation_token: user.confirmation_token
|
||||
get :show, params: { confirmation_token: user.confirmation_token }
|
||||
user.reload
|
||||
expect(user.confirmed?).to eq true
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue