open-nomad/ui/tests/pages/storage/volumes/detail.js
Buck Doyle 7e4c746c82
Move breadcrumbs objects into shared layout object (#9576)
Various page objects had breadcrumbs and breadcrumbFor within them, this
moves those to the existing Layout page object that contains shared page objects.
2020-12-10 11:51:22 -06:00

34 lines
1.1 KiB
JavaScript

import { create, isPresent, text, visitable } from 'ember-cli-page-object';
import allocations from 'nomad-ui/tests/pages/components/allocations';
export default create({
visit: visitable('/csi/volumes/:id'),
title: text('[data-test-title]'),
health: text('[data-test-volume-health]'),
provider: text('[data-test-volume-provider]'),
externalId: text('[data-test-volume-external-id]'),
hasNamespace: isPresent('[data-test-volume-namespace]'),
namespace: text('[data-test-volume-namespace]'),
...allocations('[data-test-read-allocation]', 'readAllocations'),
...allocations('[data-test-write-allocation]', 'writeAllocations'),
writeTableIsEmpty: isPresent('[data-test-empty-write-allocations]'),
writeEmptyState: {
headline: text('[data-test-empty-write-allocations-headline]'),
},
readTableIsEmpty: isPresent('[data-test-empty-read-allocations]'),
readEmptyState: {
headline: text('[data-test-empty-read-allocations-headline]'),
},
constraints: {
accessMode: text('[data-test-access-mode]'),
attachmentMode: text('[data-test-attachment-mode]'),
},
});