2018-08-28 05:03:55 +00:00
|
|
|
import { create, visitable, fillable } from 'ember-cli-page-object';
|
|
|
|
import mountForm from 'vault/tests/pages/components/mount-backend-form';
|
2018-09-25 16:28:26 +00:00
|
|
|
import withFlash from 'vault/tests/helpers/with-flash';
|
2018-04-03 14:16:57 +00:00
|
|
|
|
|
|
|
export default create({
|
|
|
|
visit: visitable('/vault/settings/mount-secret-backend'),
|
2018-08-28 05:03:55 +00:00
|
|
|
...mountForm,
|
|
|
|
version: fillable('[data-test-input="options.version"]'),
|
|
|
|
maxTTLVal: fillable('[data-test-input="config.maxLeaseTtl"] [data-test-ttl-value]'),
|
|
|
|
maxTTLUnit: fillable('[data-test-input="config.maxLeaseTtl"] [data-test-ttl-unit]'),
|
|
|
|
defaultTTLVal: fillable('[data-test-input="config.defaultLeaseTtl"] [data-test-ttl-value]'),
|
|
|
|
defaultTTLUnit: fillable('[data-test-input="config.defaultLeaseTtl"] [data-test-ttl-unit]'),
|
2018-09-25 16:28:26 +00:00
|
|
|
enable: async function(type, path) {
|
|
|
|
await this.visit();
|
|
|
|
return withFlash(this.mount(type, path));
|
|
|
|
},
|
2018-04-03 14:16:57 +00:00
|
|
|
});
|