Commit 08141295 authored by Riccardo Padovani's avatar Riccardo Padovani

#33641: add spec for profile page

parent 4c2df7d4
require 'spec_helper'
describe 'profiles/show' do
let(:user) { create(:user) }
before do
assign(:user, user)
allow(controller).to receive(:current_user).and_return(user)
end
context 'when the profile page is opened' do
it 'displays the correct elements' do
render
expect(rendered).to have_field("user_name", user.name)
expect(rendered).to have_field("user_id", user.id)
end
end
end
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