debian-mirror-gitlab/spec/helpers/users_helper_spec.rb

18 lines
372 B
Ruby
Raw Normal View History

2017-08-17 22:00:37 +05:30
require 'rails_helper'
describe UsersHelper do
let(:user) { create(:user) }
describe '#user_link' do
subject { helper.user_link(user) }
it "links to the user's profile" do
is_expected.to include("href=\"#{user_path(user)}\"")
end
it "has the user's email as title" do
is_expected.to include("title=\"#{user.email}\"")
end
end
end