Skip to content

Commit

Permalink
[Advanced Settings] Change role in security functional tests (#186602)
Browse files Browse the repository at this point in the history
Closes #184813

## Summary

This PR adds a role-based login in the advanced settings functional
tests for security serverless project instead of using normal login
where we use operator privileges. It also moves the test file to a more
appropriate folder.
  • Loading branch information
ElenaStoeva authored Jun 21, 2024
1 parent d16d402 commit 44bdb82
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@

import expect from '@kbn/expect';
import { SECURITY_PROJECT_SETTINGS } from '@kbn/serverless-security-settings';
import { FtrProviderContext } from '../../ftr_provider_context';
import { isEditorFieldSetting } from '../common/management/advanced_settings';
import { FtrProviderContext } from '../../../ftr_provider_context';
import { isEditorFieldSetting } from '../../common/management/advanced_settings';

export default ({ getPageObjects, getService }: FtrProviderContext) => {
const testSubjects = getService('testSubjects');
Expand All @@ -18,7 +18,7 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => {

describe('Security advanced settings', function () {
before(async () => {
await pageObjects.svlCommonPage.login();
await pageObjects.svlCommonPage.loginWithRole('admin');
await pageObjects.common.navigateToApp('settings');
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export default function ({ loadTestFile }: FtrProviderContext) {
loadTestFile(require.resolve('./ftr/landing_page'));
loadTestFile(require.resolve('./ftr/navigation'));
loadTestFile(require.resolve('./ftr/cases'));
loadTestFile(require.resolve('./advanced_settings'));
loadTestFile(require.resolve('./ftr/advanced_settings'));
loadTestFile(require.resolve('./ml'));
});
}

0 comments on commit 44bdb82

Please sign in to comment.