Skip to content

Commit

Permalink
Fix flaky test delete_unknown_types.ts (#174459)
Browse files Browse the repository at this point in the history
## Summary

Address #164387

This PR removes the `mappings.json` file of the related archive, getting
rid of the SO index definitions.
NB that ES archiver removes + recreates SO indices when finding custom
definitions, which has proven to be a source of flakiness.

---------

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
  • Loading branch information
gsoldevila and kibanamachine committed Jan 9, 2024
1 parent a23c6c0 commit 4899b71
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 534 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
*/

import expect from '@kbn/expect';
import { FtrProviderContext } from '../../ftr_provider_context';
import type { FtrProviderContext } from '../../ftr_provider_context';

const delay = (ms: number) => new Promise((resolve) => setTimeout(resolve, ms));

Expand All @@ -16,10 +16,10 @@ export default function ({ getService }: FtrProviderContext) {
const esArchiver = getService('esArchiver');
const es = getService('es');

// FLAKY: https://github.com/elastic/kibana/issues/164387
describe.skip('/deprecations/_delete_unknown_types', () => {
describe('/deprecations/_delete_unknown_types', () => {
before(async () => {
await esArchiver.emptyKibanaIndex();
// we are injecting unknown types in this archive, so we need to relax the mappings restrictions
await es.indices.putMapping({ index: '.kibana', body: { dynamic: true } });
await esArchiver.load(
'test/api_integration/fixtures/es_archiver/saved_objects/delete_unknown_types'
);
Expand Down

0 comments on commit 4899b71

Please sign in to comment.