Skip to content
代码片段 群组 项目
提交 6581a564 编辑于 作者: Vasilii Iakliushin's avatar Vasilii Iakliushin
浏览文件

Merge branch 'update-qa-selectors-to-testid-qa-pages-dashboard' into 'master'

No related branches found
No related tags found
无相关合并请求
......@@ -81,7 +81,6 @@ export default {
:value="searchKey"
:placeholder="__('Search labels')"
:disabled="labelsFetchInProgress"
data-qa-selector="dropdown_input_field"
data-testid="dropdown-input-field"
@input="$emit('input', $event)"
@keydown.enter="$emit('searchEnter', $event)"
......
......@@ -110,7 +110,7 @@ def dropdown_title(title, options: {})
def dropdown_filter(placeholder, search_id: nil)
content_tag :div, class: "dropdown-input" do
filter_output = search_field_tag search_id, nil, data: { qa_selector: "dropdown_input_field" }, id: nil, class: "dropdown-input-field", placeholder: placeholder, autocomplete: 'off'
filter_output = search_field_tag search_id, nil, data: { testid: "dropdown-input-field" }, id: nil, class: "dropdown-input-field", placeholder: placeholder, autocomplete: 'off'
filter_output << sprite_icon('search', css_class: 'dropdown-input-search')
filter_output << sprite_icon('close', size: 16, css_class: 'dropdown-input-clear js-dropdown-input-clear')
......
......@@ -33,7 +33,7 @@
- if todo.note.present?
\:
%span.action-name{ data: { qa_selector: "todo_action_name_content" } }<
%span.action-name{ data: { testid: "todo-action-name-content" } }<
- if !todo.note.present?
= todo_action_name(todo)
- unless todo.self_assigned?
......
......@@ -78,7 +78,7 @@
.row.js-todos-all
- if @allowed_todos.any?
.col.js-todos-list-container{ data: { qa_selector: "todos_list_container" } }
.col.js-todos-list-container{ data: { testid: "todos-list-container" } }
.js-todos-options{ data: { per_page: @allowed_todos.count, current_page: @todos.current_page, total_pages: @todos.total_pages } }
%ul.content-list.todos-list
= render @allowed_todos
......
......@@ -7,18 +7,18 @@ class Todos < Page::Base
include Page::Component::Snippet
view 'app/views/dashboard/todos/index.html.haml' do
element :todos_list_container, required: true
element 'todos-list-container', required: true
element 'group-dropdown'
end
view 'app/views/dashboard/todos/_todo.html.haml' do
element 'todo-item-container'
element :todo_action_name_content
element 'todo-action-name-content'
element 'todo-author-name-content'
end
view 'app/helpers/dropdowns_helper.rb' do
element :dropdown_input_field
element 'dropdown-input-field'
element 'dropdown-list-content'
end
......@@ -33,7 +33,7 @@ def has_no_todo_list?
def filter_todos_by_group(group)
click_element 'group-dropdown'
fill_element(:dropdown_input_field, group.path)
fill_element('dropdown-input-field', group.path)
within_element('dropdown-list-content') do
click_on group.path
......@@ -54,9 +54,9 @@ def has_latest_todo_with_author?(author:, action:)
private
def has_latest_todo_with_content?(action, **kwargs)
within_element(:todos_list_container) do
within_element('todos-list-container') do
within_element_by_index('todo-item-container', 0) do
has_element?(:todo_action_name_content, text: action) &&
has_element?('todo-action-name-content', text: action) &&
has_element?(kwargs[:selector], text: kwargs[:text])
end
end
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册