2020-04-21 14:21:52 +00:00
|
|
|
export default function(visitable, attribute, collection, text, intentions, filter, tabs) {
|
2018-07-04 14:06:20 +00:00
|
|
|
return {
|
|
|
|
visit: visitable('/:dc/services/:service'),
|
2020-04-21 14:21:52 +00:00
|
|
|
externalSource: attribute('data-test-external-source', '[data-test-external-source]', {
|
2020-05-07 13:57:15 +00:00
|
|
|
scope: '.title',
|
2020-04-21 14:21:52 +00:00
|
|
|
}),
|
2019-05-02 13:35:42 +00:00
|
|
|
dashboardAnchor: {
|
|
|
|
href: attribute('href', '[data-test-dashboard-anchor]'),
|
|
|
|
},
|
2020-05-12 21:34:47 +00:00
|
|
|
tabs: tabs('tab', ['instances', 'linked-services', 'intentions', 'routing', 'tags']),
|
2018-07-04 14:06:20 +00:00
|
|
|
filter: filter,
|
2020-04-16 14:15:45 +00:00
|
|
|
|
|
|
|
// TODO: These need to somehow move to subpages
|
2020-04-21 14:21:52 +00:00
|
|
|
instances: collection('.consul-service-instance-list > ul > li:not(:first-child)', {
|
2020-04-16 14:15:45 +00:00
|
|
|
address: text('[data-test-address]'),
|
|
|
|
}),
|
|
|
|
intentions: intentions(),
|
2020-05-12 21:34:47 +00:00
|
|
|
services: collection('.gateway-services-list> ul > li:not(:first-child)', {
|
|
|
|
name: text('[data-test-service-name]'),
|
|
|
|
}),
|
2018-07-04 14:06:20 +00:00
|
|
|
};
|
|
|
|
}
|