kibana/x-pack/test/functional/page_objects/api_keys_page.ts
Rashmi Kulkarni c4df77e604
configurable test users for xpack -homepage tests. (#60808)
* configurable test users for xpack

* removed exclusive tests

* added data-test-subj for the access denied page

* updated the JEST snapshot, cleaned up the test

* changes to the test_api_keys role

* more changes to consolidate the page object function

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-03-26 13:08:20 -07:00

25 lines
792 B
TypeScript

/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License;
* you may not use this file except in compliance with the Elastic License.
*/
import { FtrProviderContext } from '../ftr_provider_context';
export function ApiKeysPageProvider({ getService }: FtrProviderContext) {
const testSubjects = getService('testSubjects');
return {
async noAPIKeysHeading() {
return await testSubjects.getVisibleText('noApiKeysHeader');
},
async getGoToConsoleButton() {
return await testSubjects.find('goToConsoleButton');
},
async apiKeysPermissionDeniedMessage() {
return await testSubjects.getVisibleText('apiKeysPermissionDeniedMessage');
},
};
}