John Cowen ed2444c0b5 ui: Metadata cleanup (#7767)
* Use new ConsulMetadataList for service > instance > metadata tab

* Meta Data vs Metadata everywhere (Metadata is correct)

* Fix up wording in tests
2020-05-12 17:14:40 +00:00

29 lines
1012 B
JavaScript

export default function(visitable, deletable, clickable, attribute, collection, tabs) {
return {
visit: visitable('/:dc/nodes/:node'),
tabs: tabs('tab', [
'health-checks',
'services',
'round-trip-time',
'lock-sessions',
'metadata',
]),
healthchecks: collection('[data-test-node-healthcheck]', {
name: attribute('data-test-node-healthcheck'),
}),
services: collection('#services [data-test-tabular-row]', {
id: attribute('data-test-service-id', '[data-test-service-id]'),
name: attribute('data-test-service-name', '[data-test-service-name]'),
port: attribute('data-test-service-port', '.port'),
externalSource: attribute('data-test-external-source', 'a span'),
}),
sessions: collection(
'#lock-sessions [data-test-tabular-row]',
deletable({
TTL: attribute('data-test-session-ttl', '[data-test-session-ttl]'),
})
),
metadata: collection('#metadata [data-test-tabular-row]', {}),
};
}