mirror of
https://github.com/hashicorp/vault.git
synced 2025-08-22 23:21:08 +02:00
* adding skip flag to db creation * update field name & add default val change to static role * transfer both fields to be toggle buttons * add changelog * test updates * leftover * test fixes * fix tests pt2 * test pt3 * adding conditional to disable role type selection * adding alert when overriding db default * cleanup * pr comments pt1 - updates to logic, adding empty state & form field test * moving empty state placement * updating form field logic for subtext, test fixes * restructuring a bit to use a getter / eliminate separate function * update * fix typo, bring back tests * fixes and cleanup
55 lines
1.8 KiB
JavaScript
55 lines
1.8 KiB
JavaScript
/**
|
|
* Copyright (c) HashiCorp, Inc.
|
|
* SPDX-License-Identifier: BUSL-1.1
|
|
*/
|
|
|
|
import {
|
|
attribute,
|
|
focusable,
|
|
value,
|
|
clickable,
|
|
isPresent,
|
|
collection,
|
|
fillable,
|
|
triggerable,
|
|
text,
|
|
} from 'ember-cli-page-object';
|
|
|
|
export default {
|
|
hasStringList: isPresent('[data-test-component=string-list]'),
|
|
hasTextFile: isPresent('[data-test-component=text-file]'),
|
|
hasTTLPicker: isPresent('[data-test-toggle-input="Foo"]'),
|
|
hasToggleButton: isPresent('[data-test-toggle-input="toggle-foobar"]'),
|
|
hasJSONEditor: isPresent('[data-test-component="code-mirror-modifier"]'),
|
|
hasJSONClearButton: isPresent('[data-test-json-clear-button]'),
|
|
hasInput: isPresent('input'),
|
|
hasCheckbox: isPresent('input[type=checkbox]'),
|
|
hasTextarea: isPresent('textarea'),
|
|
hasMaskedInput: isPresent('[data-test-masked-input]'),
|
|
hasTooltip: isPresent('[data-test-component=info-tooltip]'),
|
|
tooltipTrigger: focusable('[data-test-tool-tip-trigger]'),
|
|
hasRadio: isPresent('[data-test-radio-input]'),
|
|
radioButtons: collection('input[type=radio]', {
|
|
select: clickable(),
|
|
id: attribute('id'),
|
|
}),
|
|
|
|
fields: collection('[data-test-field]', {
|
|
clickLabel: clickable('label'),
|
|
toggleTtl: clickable('[data-test-toggle-input="Foo"]'),
|
|
toggleButton: clickable('[data-test-toggle-input="toggle-foobar"]'),
|
|
labelValue: text('[data-test-form-field-label]'),
|
|
input: fillable('input'),
|
|
ttlTime: fillable('[data-test-ttl-value]'),
|
|
select: fillable('select'),
|
|
textarea: fillable('textarea'),
|
|
change: triggerable('keyup', '.input'),
|
|
inputValue: value('input'),
|
|
textareaValue: value('textarea'),
|
|
inputChecked: attribute('checked', 'input[type=checkbox]'),
|
|
}),
|
|
selectRadioInput: async function (value) {
|
|
return this.radioButtons.filterBy('id', value)[0].select();
|
|
},
|
|
};
|