Skip to content

Commit

Permalink
Revert "replace es_archiver/empty_kibana with cleanStandardList (elas…
Browse files Browse the repository at this point in the history
…tic#139324)"

This reverts commit 220578b.
  • Loading branch information
spalger authored and Mpdreamz committed Sep 6, 2022
1 parent 2f5b0e5 commit c638c61
Show file tree
Hide file tree
Showing 5 changed files with 491 additions and 6 deletions.
5 changes: 2 additions & 3 deletions test/functional/apps/dashboard_elements/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,19 @@ export default function ({ getService, loadTestFile }: FtrProviderContext) {
const browser = getService('browser');
const log = getService('log');
const esArchiver = getService('esArchiver');
const kibanaServer = getService('kibanaServer');

describe('dashboard elements', () => {
before(async () => {
log.debug('Starting before method');
await browser.setWindowSize(1280, 800);
await kibanaServer.savedObjects.cleanStandardList();
await esArchiver.load('test/functional/fixtures/es_archiver/empty_kibana');

await esArchiver.loadIfNeeded('test/functional/fixtures/es_archiver/logstash_functional');
await esArchiver.loadIfNeeded('test/functional/fixtures/es_archiver/long_window_logstash');
});

after(async () => {
await kibanaServer.savedObjects.cleanStandardList();
await esArchiver.unload('test/functional/fixtures/es_archiver/empty_kibana');
await esArchiver.unload('test/functional/fixtures/es_archiver/logstash_functional');
await esArchiver.unload('test/functional/fixtures/es_archiver/long_window_logstash');
});
Expand Down
4 changes: 1 addition & 3 deletions test/functional/apps/management/_handle_alias.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,12 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
const retry = getService('retry');
const security = getService('security');
const PageObjects = getPageObjects(['common', 'home', 'settings', 'discover', 'timePicker']);
const kibanaServer = getService('kibanaServer');

describe('Index patterns on aliases', function () {
before(async function () {
await kibanaServer.savedObjects.cleanStandardList();
await security.testUser.setRoles(['kibana_admin', 'test_alias_reader']);
await esArchiver.loadIfNeeded('test/functional/fixtures/es_archiver/alias');
await esArchiver.load('test/functional/fixtures/es_archiver/empty_kibana');
await es.indices.updateAliases({
body: {
actions: [
Expand Down Expand Up @@ -77,7 +76,6 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
after(async () => {
await PageObjects.common.unsetTime();
await security.testUser.restoreDefaults();
await kibanaServer.savedObjects.cleanStandardList();
await esArchiver.unload('test/functional/fixtures/es_archiver/alias');
});
});
Expand Down
Binary file not shown.
243 changes: 243 additions & 0 deletions test/functional/fixtures/es_archiver/empty_kibana/mappings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,243 @@
{
"type": "index",
"value": {
"aliases": {
".kibana": {}
},
"index": ".kibana_1",
"mappings": {
"properties": {
"config": {
"dynamic": "true",
"properties": {
"buildNum": {
"type": "keyword"
},
"dateFormat:tz": {
"fields": {
"keyword": {
"ignore_above": 256,
"type": "keyword"
}
},
"type": "text"
}
}
},
"dashboard": {
"dynamic": "strict",
"properties": {
"description": {
"type": "text"
},
"hits": {
"type": "integer"
},
"kibanaSavedObjectMeta": {
"properties": {
"searchSourceJSON": {
"type": "text"
}
}
},
"optionsJSON": {
"type": "text"
},
"panelsJSON": {
"type": "text"
},
"refreshInterval": {
"properties": {
"display": {
"type": "keyword"
},
"pause": {
"type": "boolean"
},
"section": {
"type": "integer"
},
"value": {
"type": "integer"
}
}
},
"timeFrom": {
"type": "keyword"
},
"timeRestore": {
"type": "boolean"
},
"timeTo": {
"type": "keyword"
},
"title": {
"type": "text"
},
"uiStateJSON": {
"type": "text"
},
"version": {
"type": "integer"
}
}
},
"index-pattern": {
"dynamic": "strict",
"properties": {
"fieldFormatMap": {
"type": "text"
},
"fields": {
"type": "text"
},
"intervalName": {
"type": "keyword"
},
"notExpandable": {
"type": "boolean"
},
"sourceFilters": {
"type": "text"
},
"timeFieldName": {
"type": "keyword"
},
"title": {
"type": "text"
}
}
},
"search": {
"dynamic": "strict",
"properties": {
"columns": {
"type": "keyword"
},
"description": {
"type": "text"
},
"hits": {
"type": "integer"
},
"kibanaSavedObjectMeta": {
"properties": {
"searchSourceJSON": {
"type": "text"
}
}
},
"sort": {
"type": "keyword"
},
"title": {
"type": "text"
},
"version": {
"type": "integer"
}
}
},
"server": {
"dynamic": "strict",
"properties": {
"uuid": {
"type": "keyword"
}
}
},
"type": {
"type": "keyword"
},
"url": {
"dynamic": "strict",
"properties": {
"accessCount": {
"type": "long"
},
"accessDate": {
"type": "date"
},
"createDate": {
"type": "date"
},
"url": {
"fields": {
"keyword": {
"ignore_above": 2048,
"type": "keyword"
}
},
"type": "text"
}
}
},
"visualization": {
"dynamic": "strict",
"properties": {
"description": {
"type": "text"
},
"kibanaSavedObjectMeta": {
"properties": {
"searchSourceJSON": {
"type": "text"
}
}
},
"savedSearchId": {
"type": "keyword"
},
"title": {
"type": "text"
},
"uiStateJSON": {
"type": "text"
},
"version": {
"type": "integer"
},
"visState": {
"type": "text"
}
}
},
"query": {
"properties": {
"title": {
"type": "text"
},
"description": {
"type": "text"
},
"query": {
"properties": {
"language": {
"type": "keyword"
},
"query": {
"type": "keyword",
"index": false
}
}
},
"filters": {
"type": "object",
"enabled": false
},
"timefilter": {
"type": "object",
"enabled": false
}
}
}
}
},
"settings": {
"index": {
"number_of_replicas": "1",
"number_of_shards": "1"
}
}
}
}
Loading

0 comments on commit c638c61

Please sign in to comment.