Sha256: 1e8e6446934c051b106641af9fa25126e3449d368d0b84c1649818a8e2cf5c90
Contents?: true
Size: 730 Bytes
Versions: 152
Compression:
Stored size: 730 Bytes
Contents
require 'rails_helper' describe Users::ConfirmationsController do render_views before do @request.env['devise.mapping'] = Devise.mappings[:user] # rubocop:disable RSpec/InstanceVariable end describe '#show sin el token' do subject { get :show } it do subject expect(response).to have_http_status(:ok) end end describe '#show con el token' do subject { get :show, params: { confirmation_token: 'bla' } } let(:user) { create :user, confirmed_at: nil, confirmation_token: 'bla' } it do subject expect(response).to have_http_status(:ok) end it do expect { subject }.to change { user.reload.confirmed_at }.from(nil).to(be_present) end end end
Version data entries
152 entries across 152 versions & 1 rubygems