Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/presenters/user_presenter_spec.rb')
-rw-r--r--spec/presenters/user_presenter_spec.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/presenters/user_presenter_spec.rb b/spec/presenters/user_presenter_spec.rb
index 883eec68304..d1124d73dbd 100644
--- a/spec/presenters/user_presenter_spec.rb
+++ b/spec/presenters/user_presenter_spec.rb
@@ -17,6 +17,14 @@ RSpec.describe UserPresenter do
it { expect(presenter.web_url).to eq("http://localhost/#{user.username}") }
end
+ describe '#can?' do
+ it 'forwards call to the given user' do
+ expect(user).to receive(:can?).with("a", b: 24)
+
+ presenter.send(:can?, "a", b: 24)
+ end
+ end
+
context 'Gitpod' do
let(:gitpod_url) { "https://gitpod.io" }
let(:gitpod_application_enabled) { true }