2020-07-23 11:09:28 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
require 'spec_helper'
|
|
|
|
|
|
|
|
RSpec.describe UserPresenter do
|
|
|
|
let_it_be(:user) { create(:user) }
|
2021-04-21 05:09:15 -04:00
|
|
|
|
2020-07-23 11:09:28 -04:00
|
|
|
subject(:presenter) { described_class.new(user) }
|
|
|
|
|
|
|
|
describe '#web_path' do
|
|
|
|
it { expect(presenter.web_path).to eq("/#{user.username}") }
|
|
|
|
end
|
|
|
|
|
|
|
|
describe '#web_url' do
|
|
|
|
it { expect(presenter.web_url).to eq("http://localhost/#{user.username}") }
|
|
|
|
end
|
|
|
|
end
|