Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Archive Migration] x-pack spaces/enter_space #135200

Merged
merged 6 commits into from
Jul 12, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 29 additions & 6 deletions x-pack/test/functional/apps/spaces/enter_space.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,22 +7,45 @@

import { FtrProviderContext } from '../../ftr_provider_context';

export default function enterSpaceFunctonalTests({
export default function enterSpaceFunctionalTests({
getService,
getPageObjects,
}: FtrProviderContext) {
const esArchiver = getService('esArchiver');
const kibanaServer = getService('kibanaServer');
const PageObjects = getPageObjects(['security', 'spaceSelector']);
const spacesService = getService('spaces');

describe('Enter Space', function () {
this.tags('includeFirefox');
before(async () => {
await esArchiver.load('x-pack/test/functional/es_archives/spaces/enter_space');
await spacesService.create({
id: 'another-space',
name: 'Another Space',
disabledFeatures: [],
});
await kibanaServer.uiSettings.replace(
{
defaultRoute: '/app/canvas',
buildNum: 8467,
'dateFormat:tz': 'UTC',
},
{ space: 'another-space' }
);
const config = await kibanaServer.savedObjects.get({
id: await kibanaServer.version.get(),
type: 'config',
});
await kibanaServer.savedObjects.update({
id: config.id,
type: config.type,
attributes: { defaultRoute: 'http://example.com/evil' },
});
await PageObjects.security.forceLogout();
});
after(
async () => await esArchiver.unload('x-pack/test/functional/es_archives/spaces/enter_space')
);
after(async () => {
await spacesService.delete('another-space');
await kibanaServer.savedObjects.cleanStandardList();
});

afterEach(async () => {
// NOTE: Logout needs to happen before anything else to avoid flaky behavior
Expand Down
83 changes: 0 additions & 83 deletions x-pack/test/functional/es_archives/spaces/enter_space/data.json

This file was deleted.

Loading