diff options
author | Luke Duncalfe <lduncalfe@eml.cc> | 2019-01-15 05:11:04 +0300 |
---|---|---|
committer | Yorick Peterse <yorickpeterse@gmail.com> | 2019-01-31 18:51:18 +0300 |
commit | f27cba0feef5d664c97082a0fe1b2e4b3d62f839 (patch) | |
tree | b8841cbe906feb0768947fc2b45bf8447966a0aa /spec | |
parent | 29521953c356fba5795b5900de191479edfd0fd5 (diff) |
Fix private user email being visible in tag webhooks
Fixes #54721
Diffstat (limited to 'spec')
-rw-r--r-- | spec/lib/gitlab/data_builder/push_spec.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/lib/gitlab/data_builder/push_spec.rb b/spec/lib/gitlab/data_builder/push_spec.rb index d70438ba27c..0c4decc6518 100644 --- a/spec/lib/gitlab/data_builder/push_spec.rb +++ b/spec/lib/gitlab/data_builder/push_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' describe Gitlab::DataBuilder::Push do let(:project) { create(:project, :repository) } - let(:user) { build(:user) } + let(:user) { build(:user, public_email: 'public-email@example.com') } describe '.build_sample' do let(:data) { described_class.build_sample(project, user) } @@ -36,7 +36,7 @@ describe Gitlab::DataBuilder::Push do it { expect(data[:user_id]).to eq(user.id) } it { expect(data[:user_name]).to eq(user.name) } it { expect(data[:user_username]).to eq(user.username) } - it { expect(data[:user_email]).to eq(user.email) } + it { expect(data[:user_email]).to eq(user.public_email) } it { expect(data[:user_avatar]).to eq(user.avatar_url) } it { expect(data[:project_id]).to eq(project.id) } it { expect(data[:project]).to be_a(Hash) } |