Skip to content
Closed
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
3 changes: 2 additions & 1 deletion test/functional/apps/management/_field_formatter.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@ export default function ({ getService, getPageObjects }) {

before(async function () {
await browser.setWindowSize(1200, 800);
await esArchiver.load('discover');
await kibanaServer.savedObjects.clean({ types: ['search'] });
await kibanaServer.importExport.load('discover');
await kibanaServer.uiSettings.replace({});
await kibanaServer.uiSettings.update({});
});
Expand Down
3 changes: 2 additions & 1 deletion test/functional/apps/management/_handle_alias.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import expect from '@kbn/expect';

export default function ({ getService, getPageObjects }) {
const esArchiver = getService('esArchiver');
const kibanaServer = getService('kibanaServer');
const es = getService('es');
const retry = getService('retry');
const security = getService('security');
Expand All @@ -19,7 +20,7 @@ export default function ({ getService, getPageObjects }) {
before(async function () {
await security.testUser.setRoles(['kibana_admin', 'test_alias_reader']);
await esArchiver.loadIfNeeded('alias');
await esArchiver.load('empty_kibana');
await kibanaServer.savedObjects.clean({ types: ['search'] });
await es.indices.updateAliases({
body: {
actions: [
Expand Down
5 changes: 3 additions & 2 deletions test/functional/apps/management/_handle_version_conflict.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import expect from '@kbn/expect';

export default function ({ getService, getPageObjects }) {
const testSubjects = getService('testSubjects');
const esArchiver = getService('esArchiver');
const kibanaServer = getService('kibanaServer');
const browser = getService('browser');
const es = getService('es');
const retry = getService('retry');
Expand All @@ -30,7 +30,8 @@ export default function ({ getService, getPageObjects }) {
describe('index version conflict', function describeIndexTests() {
before(async function () {
await browser.setWindowSize(1200, 800);
await esArchiver.load('discover');
await kibanaServer.savedObjects.clean({ types: ['search'] });
await kibanaServer.importExport.load('discover');
});

it('Should be able to surface version conflict notification while creating scripted field', async function () {
Expand Down
7 changes: 4 additions & 3 deletions test/functional/apps/management/_import_objects.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,15 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
describe('import objects', function describeIndexTests() {
describe('.ndjson file', () => {
beforeEach(async function () {
await esArchiver.load('management');
await kibanaServer.savedObjects.clean({ types: ['search'] });
await kibanaServer.importExport.load('management');
await kibanaServer.uiSettings.replace({});
await PageObjects.settings.navigateTo();
await PageObjects.settings.clickKibanaSavedObjects();
});

afterEach(async function () {
await esArchiver.unload('management');
await kibanaServer.importExport.unload('management');
});

it('should import saved objects', async function () {
Expand Down Expand Up @@ -220,7 +221,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
});

afterEach(async function () {
await esArchiver.unload('saved_objects_imports');
await kibanaServer.savedObjects.clean({ types: ['search'] });
});

it('should import saved objects', async function () {
Expand Down
8 changes: 4 additions & 4 deletions test/functional/apps/management/_mgmt_import_saved_objects.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,21 @@ import expect from '@kbn/expect';
import path from 'path';

export default function ({ getService, getPageObjects }) {
const esArchiver = getService('esArchiver');
const kibanaServer = getService('kibanaServer');
const PageObjects = getPageObjects(['common', 'settings', 'header', 'savedObjects']);

//in 6.4.0 bug the Saved Search conflict would be resolved and get imported but the visualization
//that referenced the saved search was not imported.( https://github.com/elastic/kibana/issues/22238)

describe('mgmt saved objects', function describeIndexTests() {
beforeEach(async function () {
await esArchiver.emptyKibanaIndex();
await esArchiver.load('discover');
await kibanaServer.savedObjects.clean({ types: ['search'] });
await kibanaServer.importExport.load('discover');
await PageObjects.settings.navigateTo();
});

afterEach(async function () {
await esArchiver.unload('discover');
await kibanaServer.importExport.unload('discover');
});

it('should import saved objects mgmt', async function () {
Expand Down
4 changes: 2 additions & 2 deletions test/functional/apps/management/_runtime_fields.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
import expect from '@kbn/expect';

export default function ({ getService, getPageObjects }) {
const esArchiver = getService('esArchiver');
const kibanaServer = getService('kibanaServer');
const log = getService('log');
const browser = getService('browser');
Expand All @@ -23,7 +22,8 @@ export default function ({ getService, getPageObjects }) {

before(async function () {
await browser.setWindowSize(1200, 800);
await esArchiver.load('discover');
await kibanaServer.savedObjects.clean({ types: ['search'] });
await kibanaServer.importExport.load('discover');
// delete .kibana index and then wait for Kibana to re-create it
await kibanaServer.uiSettings.replace({});
await kibanaServer.uiSettings.update({});
Expand Down
4 changes: 2 additions & 2 deletions test/functional/apps/management/_scripted_fields.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
import expect from '@kbn/expect';

export default function ({ getService, getPageObjects }) {
const esArchiver = getService('esArchiver');
const kibanaServer = getService('kibanaServer');
const log = getService('log');
const browser = getService('browser');
Expand All @@ -46,7 +45,8 @@ export default function ({ getService, getPageObjects }) {

before(async function () {
await browser.setWindowSize(1200, 800);
await esArchiver.load('discover');
await kibanaServer.savedObjects.clean({ types: ['search'] });
await kibanaServer.importExport.load('discover');
// delete .kibana index and then wait for Kibana to re-create it
await kibanaServer.uiSettings.replace({});
await kibanaServer.uiSettings.update({ 'doc_table:legacy': true });
Expand Down
8 changes: 4 additions & 4 deletions test/functional/apps/management/_scripted_fields_filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,21 @@ export default function ({ getService, getPageObjects }) {
const retry = getService('retry');
const log = getService('log');
const browser = getService('browser');
const esArchiver = getService('esArchiver');
const PageObjects = getPageObjects(['settings']);

describe('filter scripted fields', function describeIndexTests() {
before(async function () {
// delete .kibana index and then wait for Kibana to re-create it
await browser.setWindowSize(1200, 800);
await esArchiver.load('management');
await kibanaServer.importExport.load('management');
// TODO: (Tre') Drop the following line once the documentation is good to go
// await kibanaServer.importExport.save('management', { types: [ 'index-pattern' ] });
await kibanaServer.uiSettings.replace({
defaultIndex: 'f1e4c910-a2e6-11e7-bb30-233be9be6a15',
});
});

after(async function () {
await esArchiver.load('empty_kibana');
await kibanaServer.savedObjects.clean({ types: ['search'] });
});

const scriptedPainlessFieldName = 'ram_pain1';
Expand Down
6 changes: 3 additions & 3 deletions test/functional/apps/management/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import { FtrProviderContext } from '../../ftr_provider_context';
export default function ({ getService, loadTestFile }: FtrProviderContext) {
const esArchiver = getService('esArchiver');

describe('management', function () {
describe.only('management app', function () {
before(async () => {
await esArchiver.unload('logstash_functional');
await esArchiver.loadIfNeeded('makelogs');
Expand All @@ -21,7 +21,7 @@ export default function ({ getService, loadTestFile }: FtrProviderContext) {
await esArchiver.unload('makelogs');
});

describe('', function () {
describe('management ciGroup7', function () {
this.tags('ciGroup7');

loadTestFile(require.resolve('./_create_index_pattern_wizard'));
Expand All @@ -37,7 +37,7 @@ export default function ({ getService, loadTestFile }: FtrProviderContext) {
loadTestFile(require.resolve('./_field_formatter'));
});

describe('', function () {
describe('management ciGroup8', function () {
this.tags('ciGroup8');

loadTestFile(require.resolve('./_index_pattern_filter'));
Expand Down
Loading