Skip to content

Commit

Permalink
[ML] Functional tests - add missing test data cleanup (#84998) (#85017)
Browse files Browse the repository at this point in the history
This PR adds a few missing cleanup calls to the after methods of the functional ML test suite and the functional basic ML test suite.
  • Loading branch information
pheyos authored Dec 4, 2020
1 parent b710b81 commit a28703b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions x-pack/test/functional/apps/ml/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,15 @@ export default function ({ getService, loadTestFile }: FtrProviderContext) {
await ml.testResources.deleteIndexPatternByTitle('ft_bank_marketing');
await ml.testResources.deleteIndexPatternByTitle('ft_ihp_outlier');
await ml.testResources.deleteIndexPatternByTitle('ft_egs_regression');
await ml.testResources.deleteIndexPatternByTitle('ft_module_sample_ecommerce');
await esArchiver.unload('ml/farequote');
await esArchiver.unload('ml/ecommerce');
await esArchiver.unload('ml/categorization');
await esArchiver.unload('ml/event_rate_nanos');
await esArchiver.unload('ml/bm_classification');
await esArchiver.unload('ml/ihp_outlier');
await esArchiver.unload('ml/egs_regression');
await esArchiver.unload('ml/module_sample_ecommerce');
await ml.testResources.resetKibanaTimeZone();
await ml.securityUI.logout();
});
Expand Down
4 changes: 4 additions & 0 deletions x-pack/test/functional_basic/apps/ml/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,13 @@ export default function ({ getService, loadTestFile }: FtrProviderContext) {
await ml.securityCommon.cleanMlUsers();
await ml.securityCommon.cleanMlRoles();

await ml.testResources.deleteSavedSearches();

await ml.testResources.deleteIndexPatternByTitle('ft_farequote');
await ml.testResources.deleteIndexPatternByTitle('ft_module_sample_ecommerce');

await esArchiver.unload('ml/farequote');
await esArchiver.unload('ml/module_sample_ecommerce');

await ml.testResources.resetKibanaTimeZone();
});
Expand Down

0 comments on commit a28703b

Please sign in to comment.