Commit 3cb4aaa8 authored by Mayra Cabrera's avatar Mayra Cabrera

Merge branch 'kp-fix-labels-refactor-qa-failure' into 'master'

QA: Fix missing label edit button selector

See merge request gitlab-org/gitlab!73547
parents 8414a224 35e615f9
......@@ -130,7 +130,7 @@ export default {
</slot>
</template>
<slot name="default">
<gl-dropdown-form class="gl-relative gl-min-h-7">
<gl-dropdown-form class="gl-relative gl-min-h-7" data-qa-selector="labels_dropdown_content">
<gl-loading-icon
v-if="isLoading"
size="md"
......
......@@ -183,6 +183,7 @@ export default {
category="tertiary"
size="small"
class="edit-link float-right"
data-qa-selector="labels_edit_button"
@click="toggleEdit"
>
{{ $options.i18n.edit }}
......
......@@ -14,12 +14,30 @@ module QA
view 'ee/app/assets/javascripts/boards/components/board_scope.vue' do
element :board_scope_modal
end
view 'ee/app/assets/javascripts/boards/components/labels_select.vue' do
element :labels_edit_button
end
view 'app/assets/javascripts/vue_shared/components/dropdown/dropdown_widget/dropdown_widget.vue' do
element :labels_dropdown_content
end
end
end
def board_scope_modal
find_element(:board_scope_modal)
end
def configure_by_label(label)
click_boards_config_button
click_element(:labels_edit_button)
find_element(:labels_dropdown_content).find('li', text: label).click
# Clicking the edit button again closes the dropdown and allows the save button to be clicked
click_element(:labels_edit_button)
click_element(:save_changes_button)
wait_boards_list_finish_loading
end
end
end
end
......
......@@ -24,14 +24,6 @@ module QA
element :create_new_board_button
end
view 'app/assets/javascripts/vue_shared/components/sidebar/labels_select_vue/dropdown_contents.vue' do
element :labels_dropdown_content
end
view 'app/assets/javascripts/vue_shared/components/sidebar/labels_select_vue/dropdown_title.vue' do
element :labels_edit_button
end
view 'app/assets/javascripts/boards/components/board_content.vue' do
element :boards_list
end
......@@ -85,6 +77,7 @@ module QA
def click_boards_config_button
click_element(:boards_config_button)
wait_for_requests
end
def click_boards_dropdown_button
......@@ -97,16 +90,6 @@ module QA
click_element(:focus_mode_button)
end
def configure_by_label(label)
click_boards_config_button
click_element(:labels_edit_button)
find_element(:labels_dropdown_content).find('li', text: label).click
# Clicking the edit button again closes the dropdown and allows the save button to be clicked
click_element(:labels_edit_button)
click_element(:save_changes_button)
wait_boards_list_finish_loading
end
def create_new_board(board_name)
click_boards_dropdown_button
click_element(:create_new_board_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