mirror of
https://github.com/kemko/nomad.git
synced 2026-01-01 16:05:42 +03:00
* Updates the Task Lifecycle Status chart to show which pre/poststart task may have failed * Default colour to prevent HDS error * De-duplicated data-test attr and added is-active and is-finished test classes * Failed and Pending state tests
42 lines
1.0 KiB
JavaScript
42 lines
1.0 KiB
JavaScript
/**
|
|
* Copyright (c) HashiCorp, Inc.
|
|
* SPDX-License-Identifier: BUSL-1.1
|
|
*/
|
|
|
|
import { clickable, collection, hasClass, text } from 'ember-cli-page-object';
|
|
|
|
export default {
|
|
scope: '[data-test-lifecycle-chart]',
|
|
|
|
title: text('.boxed-section-head'),
|
|
|
|
phases: collection('[data-test-lifecycle-phase]', {
|
|
name: text('[data-test-name]'),
|
|
|
|
isActive: hasClass('is-active'),
|
|
}),
|
|
|
|
tasks: collection('[data-test-lifecycle-task]', {
|
|
name: text('[data-test-name]'),
|
|
lifecycle: text('[data-test-lifecycle]'),
|
|
|
|
isActive: hasClass('is-active'),
|
|
isFinished: hasClass('is-finished'),
|
|
|
|
child: {
|
|
scope: '.hds-alert',
|
|
failed: hasClass('hds-alert--color-critical'),
|
|
pending: hasClass('pending'),
|
|
},
|
|
|
|
isMain: hasClass('main'),
|
|
isPrestartEphemeral: hasClass('prestart-ephemeral'),
|
|
isPrestartSidecar: hasClass('prestart-sidecar'),
|
|
isPoststartEphemeral: hasClass('poststart-ephemeral'),
|
|
isPoststartSidecar: hasClass('poststart-sidecar'),
|
|
isPoststop: hasClass('poststop'),
|
|
|
|
visit: clickable('a'),
|
|
}),
|
|
};
|