Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
071f3463
Commit
071f3463
authored
Jan 19, 2021
by
Doug Stull
Committed by
Alper Akgun
Jan 19, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix tracking property on invite members link
- to fully use cookie based approach for subject.
parent
c639d5ca
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
9 deletions
+8
-9
app/helpers/invite_members_helper.rb
app/helpers/invite_members_helper.rb
+2
-2
config/feature_flags/experiment/invite_members_new_dropdown_experiment_percentage.yml
...ent/invite_members_new_dropdown_experiment_percentage.yml
+1
-1
spec/helpers/invite_members_helper_spec.rb
spec/helpers/invite_members_helper_spec.rb
+2
-3
spec/views/layouts/header/_new_dropdown.haml_spec.rb
spec/views/layouts/header/_new_dropdown.haml_spec.rb
+3
-3
No files found.
app/helpers/invite_members_helper.rb
View file @
071f3463
...
...
@@ -27,8 +27,8 @@ module InviteMembersHelper
link_to
invite_members_url
(
form_model
),
data:
{
'track-event'
:
'click_link'
,
'track-label'
:
tracking_label
(
current_user
)
,
'track-property'
:
experiment_tracking_category_and_group
(
:invite_members_new_dropdown
,
subject:
current_user
)
'track-label'
:
tracking_label
,
'track-property'
:
experiment_tracking_category_and_group
(
:invite_members_new_dropdown
)
}
do
invite_member_link_content
end
...
...
config/feature_flags/experiment/invite_members_new_dropdown_experiment_percentage.yml
View file @
071f3463
---
name
:
invite_members_new_dropdown_experiment_percentage
introduced_by_url
:
https://gitlab.com/gitlab-org/gitlab/-/merge_requests/50069
rollout_issue_url
:
https://gitlab.com/gitlab-org/g
itlab/-/issues/268129
rollout_issue_url
:
https://gitlab.com/gitlab-org/g
rowth/team-tasks/-/issues/291
milestone
:
'
13.8'
type
:
experiment
group
:
group::expansion
...
...
spec/helpers/invite_members_helper_spec.rb
View file @
071f3463
...
...
@@ -123,7 +123,7 @@ RSpec.describe InviteMembersHelper do
before
do
allow
(
helper
).
to
receive
(
:experiment_tracking_category_and_group
)
{
'_track_property_'
}
allow
(
helper
).
to
receive
(
:tracking_label
)
.
with
(
owner
)
allow
(
helper
).
to
receive
(
:tracking_label
)
allow
(
helper
).
to
receive
(
:current_user
)
{
owner
}
end
...
...
@@ -132,8 +132,7 @@ RSpec.describe InviteMembersHelper do
helper
.
dropdown_invite_members_link
(
form_model
)
expect
(
helper
).
to
have_received
(
:experiment_tracking_category_and_group
)
.
with
(
:invite_members_new_dropdown
,
subject:
owner
)
expect
(
helper
).
to
have_received
(
:experiment_tracking_category_and_group
).
with
(
:invite_members_new_dropdown
)
end
context
'with experiment enabled'
do
...
...
spec/views/layouts/header/_new_dropdown.haml_spec.rb
View file @
071f3463
...
...
@@ -10,7 +10,7 @@ RSpec.describe 'layouts/header/_new_dropdown' do
before
do
allow
(
Gitlab
::
Experimentation
).
to
receive
(
:active?
).
and_return
(
true
)
allow
(
view
).
to
receive
(
:experiment_tracking_category_and_group
)
allow
(
view
).
to
receive
(
:tracking_label
)
.
with
(
user
)
allow
(
view
).
to
receive
(
:tracking_label
)
end
context
'with ability to invite members'
do
...
...
@@ -20,8 +20,8 @@ RSpec.describe 'layouts/header/_new_dropdown' do
subject
expect
(
view
).
to
have_received
(
:experiment_tracking_category_and_group
)
.
with
(
:invite_members_new_dropdown
,
subject:
user
)
expect
(
view
).
to
have_received
(
:tracking_label
)
.
with
(
user
)
.
with
(
:invite_members_new_dropdown
)
expect
(
view
).
to
have_received
(
:tracking_label
)
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment