Commit e02e3cea authored by Sanad Liaquat's avatar Sanad Liaquat

Merge branch 'qa-shl-fix-protected-tags-spec' into 'master'

Fix protected tags e2e test

See merge request gitlab-org/gitlab!35131
parents 1e668e66 b740ed37
- content_for :create_access_levels do - content_for :create_access_levels do
.create_access_levels-container .create_access_levels-container{ data: { qa_selector: 'access_levels_content' } }
= dropdown_tag('Select', = dropdown_tag('Select',
options: { toggle_class: 'js-allowed-to-create wide', options: { toggle_class: 'js-allowed-to-create wide',
dropdown_class: 'dropdown-menu-selectable capitalize-header', dropdown_class: 'dropdown-menu-selectable capitalize-header',
......
- content_for :create_access_levels do - content_for :create_access_levels do
.create_access_levels-container .create_access_levels-container{ data: { qa_selector: 'access_levels_content' } }
= dropdown_tag('Select', = dropdown_tag('Select',
options: { toggle_class: 'js-allowed-to-create js-multiselect wide', options: { toggle_class: 'js-allowed-to-create js-multiselect wide',
dropdown_class: 'dropdown-menu-user dropdown-menu-selectable capitalize-header', filter: true, dropdown_class: 'dropdown-menu-user dropdown-menu-selectable capitalize-header', filter: true,
......
...@@ -13,6 +13,7 @@ module QA ...@@ -13,6 +13,7 @@ module QA
base.class_eval do base.class_eval do
view 'ee/app/views/projects/protected_tags/ee/_create_protected_tag.html.haml' do view 'ee/app/views/projects/protected_tags/ee/_create_protected_tag.html.haml' do
element :access_levels_content
element :access_levels_dropdown element :access_levels_dropdown
end end
end end
......
...@@ -12,6 +12,7 @@ module QA ...@@ -12,6 +12,7 @@ module QA
end end
view 'app/views/projects/protected_tags/_create_protected_tag.html.haml' do view 'app/views/projects/protected_tags/_create_protected_tag.html.haml' do
element :access_levels_content
element :access_levels_dropdown element :access_levels_dropdown
end end
...@@ -26,7 +27,9 @@ module QA ...@@ -26,7 +27,9 @@ module QA
def choose_access_level_role(role) def choose_access_level_role(role)
click_element :access_levels_dropdown click_element :access_levels_dropdown
click_on role within_element(:access_levels_content) do
click_on role
end
end end
def click_protect_tag_button def click_protect_tag_button
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment