2020-10-24 23:57:45 +05:30
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
require 'spec_helper'
|
|
|
|
|
|
|
|
RSpec.describe UserPresenter do
|
|
|
|
let_it_be(:user) { create(:user) }
|
2021-06-08 01:23:25 +05:30
|
|
|
|
2020-10-24 23:57:45 +05:30
|
|
|
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
|