Skip to content

Commit

Permalink
[Archive Migration] x-pack..discover/feature_controls/spaces (elastic…
Browse files Browse the repository at this point in the history
…#107644)

# Conflicts:
#	x-pack/test/functional/es_archives/discover/feature_controls/spaces/mappings.json
  • Loading branch information
wayneseymour committed Aug 11, 2021
1 parent 79e45f2 commit 026220d
Show file tree
Hide file tree
Showing 5 changed files with 65 additions and 549 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {
]);
const testSubjects = getService('testSubjects');
const appsMenu = getService('appsMenu');
const kibanaServer = getService('kibanaServer');

async function setDiscoverTimeRange() {
await PageObjects.timePicker.setDefaultAbsoluteRange();
Expand All @@ -36,8 +37,12 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {
before(async () => {
// we need to load the following in every situation as deleting
// a space deletes all of the associated saved objects
await esArchiver.load(
'x-pack/test/functional/es_archives/discover/feature_controls/spaces'
await kibanaServer.importExport.load(
'x-pack/test/functional/fixtures/kbn_archiver/discover/feature_controls/spaces'
);
await kibanaServer.importExport.load(
'x-pack/test/functional/fixtures/kbn_archiver/discover/feature_controls/custom_space',
{ space: 'custom_space' }
);
await spacesService.create({
id: 'custom_space',
Expand All @@ -48,8 +53,12 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {

after(async () => {
await spacesService.delete('custom_space');
await esArchiver.unload(
'x-pack/test/functional/es_archives/discover/feature_controls/spaces'
await kibanaServer.importExport.unload(
'x-pack/test/functional/fixtures/kbn_archiver/discover/feature_controls/custom_space',
{ space: 'custom_space' }
);
await kibanaServer.importExport.unload(
'x-pack/test/functional/fixtures/kbn_archiver/discover/feature_controls/spaces'
);
});

Expand Down Expand Up @@ -84,8 +93,8 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {
before(async () => {
// we need to load the following in every situation as deleting
// a space deletes all of the associated saved objects
await esArchiver.load(
'x-pack/test/functional/es_archives/discover/feature_controls/spaces'
await kibanaServer.importExport.load(
'x-pack/test/functional/fixtures/kbn_archiver/discover/feature_controls/spaces'
);
await spacesService.create({
id: 'custom_space',
Expand All @@ -96,8 +105,8 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {

after(async () => {
await spacesService.delete('custom_space');
await esArchiver.unload(
'x-pack/test/functional/es_archives/discover/feature_controls/spaces'
await kibanaServer.importExport.unload(
'x-pack/test/functional/fixtures/kbn_archiver/discover/feature_controls/spaces'
);
});

Expand Down

This file was deleted.

Loading

0 comments on commit 026220d

Please sign in to comment.