From b1c83876ec29ad2e49240d5792212dfc55e157c4 Mon Sep 17 00:00:00 2001 From: Lee Drengenberg Date: Thu, 10 Feb 2022 16:37:29 -0600 Subject: [PATCH] replace another usage of es_archives/invalid_scripted_field --- .../apps/discover/error_handling.ts | 7 +- .../invalid_scripted_field/data.json.gz | Bin 956 -> 0 bytes .../invalid_scripted_field/mappings.json | 212 ------------------ 3 files changed, 5 insertions(+), 214 deletions(-) delete mode 100644 x-pack/test/functional/es_archives/invalid_scripted_field/data.json.gz delete mode 100644 x-pack/test/functional/es_archives/invalid_scripted_field/mappings.json diff --git a/x-pack/test/functional/apps/discover/error_handling.ts b/x-pack/test/functional/apps/discover/error_handling.ts index 19cedc8ecb555..194a9a592c1c2 100644 --- a/x-pack/test/functional/apps/discover/error_handling.ts +++ b/x-pack/test/functional/apps/discover/error_handling.ts @@ -10,19 +10,22 @@ import { FtrProviderContext } from '../../ftr_provider_context'; export default function ({ getService, getPageObjects }: FtrProviderContext) { const esArchiver = getService('esArchiver'); + const kibanaServer = getService('kibanaServer'); const toasts = getService('toasts'); const PageObjects = getPageObjects(['common', 'discover', 'timePicker']); describe('errors', function describeIndexTests() { before(async function () { await esArchiver.loadIfNeeded('x-pack/test/functional/es_archives/logstash_functional'); - await esArchiver.load('x-pack/test/functional/es_archives/invalid_scripted_field'); + await kibanaServer.importExport.load( + 'test/functional/fixtures/kbn_archiver/invalid_scripted_field' + ); await PageObjects.timePicker.setDefaultAbsoluteRangeViaUiSettings(); await PageObjects.common.navigateToApp('discover'); }); after(async function () { - await esArchiver.unload('x-pack/test/functional/es_archives/invalid_scripted_field'); + await kibanaServer.savedObjects.clean({ types: ['search', 'index-pattern'] }); }); // this is the same test as in OSS but it catches different error message issue in different licences diff --git a/x-pack/test/functional/es_archives/invalid_scripted_field/data.json.gz b/x-pack/test/functional/es_archives/invalid_scripted_field/data.json.gz deleted file mode 100644 index 380dd6049179a59865b91aef55ba5836c37dcea7..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 956 zcmV;t14H~DiwFP!000026V;nRPunmQ$M1ZKD#wXNP0MJ>Y0@U7T{ulUY)sLs{gPNX zc4j*Rg!t~W(}XsxASz&eJyfcn9s8HRpP!vLzB?L?B6nM3l#U{e?T_Da_191 zDR{_bTIHfh=kX+-j6v2VByH(XKykbYW#TKb1O>g_>c+5jMWeow4U4xe8zK2cQ+ey+ zNf6h3i$+1^NNway4tv^J(2<-Bp?|6686 z?KSer9HhlyLNKg^r3@E3(*zq7g~0+`XYGp`1b%LG^+mJqK_J`b-5+lwiVa-9BUNYJ z1{Ja%F*ztKA&CMGEq#RVH3wBaBnl&HA3T}h`;lf#XJzf6q=RFbHjjq8YN{ogopE~O z>zp}Tg|Q*grg0BQD-I$(=3`-Kk4o@qaVQ0!<*h^eCJy}uFiZ+Bk9ZUZyYzo%!5fFl z3a#ik&jS)A2P#mO5Y&?r%1G@1^UG9o6EH>M0WQycFt+P{3(%DD_eWtP~1kO-Q6Q6Gf#A zR8&Gxg_Sn9bZ8vJzCuH$#{!T+32ifEygN`e7EPQBW8KP54^F~1w*7fmUDmYR-C&Le z$vAuG=byE5;T;4RCz!;v(p=;Mc^2M6(s%*+1ZmwYrLg58pju>()T@K%IVsJePmnq& z$gAlY2`j0K)IaOD%~E#FAtr4-MMY}!?+L&I&@e4g6s03CWyg64ie3xuO8SDfn6&k@ z!eK^h75)q)Z7rQ}lC+L3AaM=fcYpQu5_&A!3N}Vk7SQ7n*3Vsw@P$;$z;LoEZbBY_ zmWQw~-@!)l zYjS1Tthc>LLb$iEe+xoM?0VxZz61XiZ5)3J4tE~tFZ|7ggFNd~7sFzHxf8ObE&C|b diff --git a/x-pack/test/functional/es_archives/invalid_scripted_field/mappings.json b/x-pack/test/functional/es_archives/invalid_scripted_field/mappings.json deleted file mode 100644 index 0d41e0ce86c14..0000000000000 --- a/x-pack/test/functional/es_archives/invalid_scripted_field/mappings.json +++ /dev/null @@ -1,212 +0,0 @@ -{ - "type": "index", - "value": { - "aliases": { - ".kibana": {} - }, - "index": ".kibana_1", - "mappings": { - "dynamic": "strict", - "properties": { - "config": { - "dynamic": "true", - "properties": { - "buildNum": { - "type": "keyword" - }, - "defaultIndex": { - "fields": { - "keyword": { - "ignore_above": 256, - "type": "keyword" - } - }, - "type": "text" - } - } - }, - "dashboard": { - "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": { - "properties": { - "fieldFormatMap": { - "type": "text" - }, - "fields": { - "type": "text" - }, - "intervalName": { - "type": "keyword" - }, - "notExpandable": { - "type": "boolean" - }, - "sourceFilters": { - "type": "text" - }, - "timeFieldName": { - "type": "keyword" - }, - "title": { - "type": "text" - } - } - }, - "search": { - "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": { - "properties": { - "uuid": { - "type": "keyword" - } - } - }, - "type": { - "type": "keyword" - }, - "updated_at": { - "type": "date" - }, - "url": { - "properties": { - "accessCount": { - "type": "long" - }, - "accessDate": { - "type": "date" - }, - "createDate": { - "type": "date" - }, - "url": { - "fields": { - "keyword": { - "ignore_above": 2048, - "type": "keyword" - } - }, - "type": "text" - } - } - }, - "visualization": { - "properties": { - "description": { - "type": "text" - }, - "kibanaSavedObjectMeta": { - "properties": { - "searchSourceJSON": { - "type": "text" - } - } - }, - "savedSearchId": { - "type": "keyword" - }, - "title": { - "type": "text" - }, - "uiStateJSON": { - "type": "text" - }, - "version": { - "type": "integer" - }, - "visState": { - "type": "text" - } - } - } - } - }, - "settings": { - "index": { - "number_of_replicas": "0", - "number_of_shards": "1" - } - } - } -} \ No newline at end of file