Commit cc61a2a1 authored by Justin Ho's avatar Justin Ho Committed by Tom Quirk

Update specs to use Vue app

- Update QA selectors
- Update translations
- Use JS in feature specs to render Vue
parent 002b9377
...@@ -55,7 +55,12 @@ export default { ...@@ -55,7 +55,12 @@ export default {
</template> </template>
<template #cell(name)="{ item }"> <template #cell(name)="{ item }">
<gl-link :href="item.edit_path" class="gl-font-weight-bold">{{ item.name }}</gl-link> <gl-link
:href="item.edit_path"
class="gl-font-weight-bold"
:data-qa-selector="`${item.type}_link`"
>{{ item.name }}</gl-link
>
</template> </template>
<template #cell(updated_at)="{ item }"> <template #cell(updated_at)="{ item }">
......
...@@ -168,7 +168,8 @@ module ServicesHelper ...@@ -168,7 +168,8 @@ module ServicesHelper
name: integration.title, name: integration.title,
description: integration.description, description: integration.description,
updated_at: integration.updated_at, updated_at: integration.updated_at,
edit_path: scoped_edit_integration_path(integration) edit_path: scoped_edit_integration_path(integration),
type: integration.to_param
} }
end end
end end
......
...@@ -10,8 +10,9 @@ module QA ...@@ -10,8 +10,9 @@ module QA
def self.prepended(base) def self.prepended(base)
base.class_eval do base.class_eval do
view 'app/views/shared/integrations/_index.html.haml' do view 'app/assets/javascripts/integrations/index/components/integrations_table.vue' do
element :jenkins_link, 'data: { qa_selector: "#{integration.to_param' # rubocop:disable QA/ElementWithPattern element :jenkins_link, %q(:data-qa-selector="`${item.type}_link`") # rubocop:disable QA/ElementWithPattern
element :jira_link, %q(:data-qa-selector="`${item.type}_link`") # rubocop:disable QA/ElementWithPattern
end end
end end
end end
......
...@@ -5,9 +5,9 @@ module QA ...@@ -5,9 +5,9 @@ module QA
module Project module Project
module Settings module Settings
class Integrations < QA::Page::Base class Integrations < QA::Page::Base
view 'app/views/shared/integrations/_index.html.haml' do view 'app/assets/javascripts/integrations/index/components/integrations_table.vue' do
element :prometheus_link, 'data: { qa_selector: "#{integration.to_param' # rubocop:disable QA/ElementWithPattern element :prometheus_link, %q(:data-qa-selector="`${item.type}_link`") # rubocop:disable QA/ElementWithPattern
element :jira_link, 'data: { qa_selector: "#{integration.to_param' # rubocop:disable QA/ElementWithPattern element :jira_link, %q(:data-qa-selector="`${item.type}_link`") # rubocop:disable QA/ElementWithPattern
end end
def click_on_prometheus_integration def click_on_prometheus_integration
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
require 'spec_helper' require 'spec_helper'
RSpec.describe 'User views services' do RSpec.describe 'User views services', :js do
include_context 'project service activation' include_context 'project service activation'
it 'shows the list of available services' do it 'shows the list of available services' do
......
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