github.com/hernad/nomad@v1.6.112/ui/tests/pages/storage/plugins/detail.js (about)

     1  /**
     2   * Copyright (c) HashiCorp, Inc.
     3   * SPDX-License-Identifier: MPL-2.0
     4   */
     5  
     6  import {
     7    clickable,
     8    create,
     9    isPresent,
    10    text,
    11    visitable,
    12  } from 'ember-cli-page-object';
    13  
    14  import allocations from 'nomad-ui/tests/pages/components/allocations';
    15  
    16  export default create({
    17    visit: visitable('/csi/plugins/:id'),
    18  
    19    title: text('[data-test-title]'),
    20  
    21    controllerHealthIsPresent: isPresent('[data-test-plugin-controller-health]'),
    22    controllerHealth: text('[data-test-plugin-controller-health]'),
    23    nodeHealth: text('[data-test-plugin-node-health]'),
    24    provider: text('[data-test-plugin-provider]'),
    25  
    26    controllerAvailabilityIsPresent: isPresent(
    27      '[data-test-plugin-controller-availability]'
    28    ),
    29    nodeAvailabilityIsPresent: isPresent('[data-test-plugin-node-availability]'),
    30  
    31    ...allocations('[data-test-controller-allocation]', 'controllerAllocations'),
    32    ...allocations('[data-test-node-allocation]', 'nodeAllocations'),
    33  
    34    goToControllerAllocations: clickable(
    35      '[data-test-go-to-controller-allocations]'
    36    ),
    37    goToNodeAllocations: clickable('[data-test-go-to-node-allocations]'),
    38    goToControllerAllocationsText: text(
    39      '[data-test-go-to-controller-allocations]'
    40    ),
    41    goToNodeAllocationsText: text('[data-test-go-to-node-allocations]'),
    42  
    43    controllerTableIsPresent: isPresent('[data-test-controller-allocations]'),
    44  
    45    controllerTableIsEmpty: isPresent('[data-test-empty-controller-allocations]'),
    46    controllerEmptyState: {
    47      headline: text('[data-test-empty-controller-allocations-headline]'),
    48    },
    49  
    50    nodeTableIsEmpty: isPresent('[data-test-empty-node-allocations]'),
    51    nodeEmptyState: {
    52      headline: text('[data-test-empty-node-allocations-headline]'),
    53    },
    54  });