diff --git a/.buildkite/ftr_platform_stateful_configs.yml b/.buildkite/ftr_platform_stateful_configs.yml index 433c8fa8d797..e46946e82cf2 100644 --- a/.buildkite/ftr_platform_stateful_configs.yml +++ b/.buildkite/ftr_platform_stateful_configs.yml @@ -151,10 +151,7 @@ enabled: - x-pack/test/api_integration_basic/config.ts - x-pack/test/api_integration/apis/cases/config.ts - x-pack/test/api_integration/apis/lists/config.ts - - x-pack/test/api_integration/apis/management/config.ts - - x-pack/test/api_integration/apis/management/index_management/disabled_data_enrichers/config.ts - x-pack/test/api_integration/apis/ml/config.ts - - x-pack/test/api_integration/apis/monitoring/config.ts - x-pack/test/api_integration/apis/search_playground/config.ts - x-pack/test/api_integration/apis/security/config.ts - x-pack/test/banners_functional/config.ts @@ -273,7 +270,6 @@ enabled: - x-pack/test/functional_search/config.ts - x-pack/test/licensing_plugin/config.public.ts - x-pack/test/licensing_plugin/config.ts - - x-pack/test/monitoring_api_integration/config.ts - x-pack/test/plugin_api_integration/config.ts - x-pack/test/plugin_functional/config.ts - x-pack/test/reporting_api_integration/reporting_and_security.config.ts @@ -284,10 +280,6 @@ enabled: - x-pack/test/rule_registry/security_and_spaces/config_trial.ts - x-pack/test/rule_registry/spaces_only/config_basic.ts - x-pack/test/rule_registry/spaces_only/config_trial.ts - - x-pack/test/saved_object_api_integration/security_and_spaces/config_basic.ts - - x-pack/test/saved_object_api_integration/security_and_spaces/config_trial.ts - - x-pack/test/saved_object_api_integration/spaces_only/config.ts - - x-pack/test/saved_object_api_integration/user_profiles/config.ts - x-pack/test/saved_object_tagging/api_integration/security_and_spaces/config.ts - x-pack/test/saved_object_tagging/api_integration/tagging_api/config.ts - x-pack/test/saved_object_tagging/api_integration/tagging_usage_collection/config.ts @@ -375,8 +367,12 @@ enabled: - x-pack/platform/test/api_integration/apis/file_upload/config.ts - x-pack/platform/test/api_integration/apis/kibana/config.ts - x-pack/platform/test/api_integration/apis/logstash/config.ts + - x-pack/platform/test/api_integration/apis/management/config.ts + - x-pack/platform/test/api_integration/apis/management/index_management/disabled_data_enrichers/config.ts - x-pack/platform/test/api_integration/apis/maps/config.ts + - x-pack/platform/test/api_integration/apis/monitoring/config.ts - x-pack/platform/test/api_integration/apis/monitoring_collection/config.ts + - x-pack/platform/test/api_integration/apis/osquery/config.ts - x-pack/platform/test/api_integration/apis/search/config.ts - x-pack/platform/test/api_integration/apis/searchprofiler/config.ts - x-pack/platform/test/api_integration/apis/security/config_security_trial.ts @@ -390,3 +386,10 @@ enabled: - x-pack/platform/test/api_integration_basic/apis/aiops/config.ts - x-pack/platform/test/api_integration_basic/apis/security/config.ts - x-pack/platform/test/api_integration_basic/apis/transform/config.ts + - x-pack/platform/test/automatic_import_api_integration/apis/config_basic.ts + - x-pack/platform/test/automatic_import_api_integration/apis/config_graphs.ts + - x-pack/platform/test/monitoring_api_integration/config.ts + - x-pack/platform/test/saved_object_api_integration/security_and_spaces/config_basic.ts + - x-pack/platform/test/saved_object_api_integration/security_and_spaces/config_trial.ts + - x-pack/platform/test/saved_object_api_integration/spaces_only/config.ts + - x-pack/platform/test/saved_object_api_integration/user_profiles/config.ts diff --git a/.buildkite/ftr_security_stateful_configs.yml b/.buildkite/ftr_security_stateful_configs.yml index e5c393743a9e..75fa543d129d 100644 --- a/.buildkite/ftr_security_stateful_configs.yml +++ b/.buildkite/ftr_security_stateful_configs.yml @@ -110,13 +110,10 @@ enabled: - x-pack/test/security_solution_endpoint/configs/endpoint.config.ts - x-pack/test/security_solution_endpoint/configs/integrations.config.ts - x-pack/test/api_integration/apis/cloud_security_posture/config.ts - - x-pack/test/api_integration/apis/osquery/config.ts - x-pack/test/cloud_security_posture_api/config.ts - x-pack/test/cloud_security_posture_functional/config.ts - x-pack/test/cloud_security_posture_functional/config.agentless.ts - x-pack/test/cloud_security_posture_functional/data_views/config.ts - - x-pack/test/automatic_import_api_integration/apis/config_basic.ts - - x-pack/test/automatic_import_api_integration/apis/config_graphs.ts - x-pack/test/spaces_api_integration/deployment_agnostic/spaces_only/config.ts - x-pack/test/spaces_api_integration/deployment_agnostic/security_and_spaces/stateful.config_basic.ts - x-pack/test/spaces_api_integration/deployment_agnostic/security_and_spaces/stateful.config_trial.ts diff --git a/.eslintrc.js b/.eslintrc.js index 3c844eee91dd..a5fd6d85be2f 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -769,7 +769,7 @@ module.exports = { 'x-pack/solutions/*/test/**/*config.*ts', 'x-pack/test/*/{tests,test_suites,apis,apps,deployment_agnostic}/**/*', 'x-pack/test/*/*config.*ts', - 'x-pack/test/saved_object_api_integration/*/apis/**/*', + 'x-pack/platform/test/saved_object_api_integration/*/apis/**/*', 'x-pack/test/ui_capabilities/*/tests/**/*', 'x-pack/test/upgrade_assistant_integration/**/*', 'x-pack/test/performance/**/*.ts', diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 471614a5b7ea..5657eadea9a9 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -945,6 +945,7 @@ x-pack/platform/plugins/shared/task_manager @elastic/response-ops x-pack/platform/plugins/shared/timelines @elastic/security-threat-hunting-investigations x-pack/platform/plugins/shared/triggers_actions_ui @elastic/response-ops x-pack/platform/test +x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin @elastic/kibana-security x-pack/solutions/chat/packages/wc-framework-types-browser @elastic/search-kibana x-pack/solutions/chat/packages/wc-framework-types-common @elastic/search-kibana x-pack/solutions/chat/packages/wc-framework-types-server @elastic/search-kibana @@ -1080,7 +1081,6 @@ x-pack/test/plugin_api_integration/plugins/sample_task_plugin @elastic/response- x-pack/test/plugin_api_perf/plugins/task_manager_performance @elastic/response-ops x-pack/test/plugin_functional/plugins/global_search_test @elastic/kibana-core x-pack/test/plugin_functional/plugins/resolver_test @elastic/security-solution -x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin @elastic/kibana-security x-pack/test/security_api_integration/packages/helpers @elastic/kibana-security x-pack/test/security_api_integration/plugins/audit_log @elastic/kibana-security x-pack/test/security_api_integration/plugins/features_provider @elastic/kibana-security @@ -1168,7 +1168,7 @@ x-pack/test_serverless/api_integration/test_suites/common/platform_security @ela /src/platform/test/functional/apps/management/data_views @elastic/kibana-data-discovery /src/platform/test/plugin_functional/test_suites/data_plugin @elastic/kibana-data-discovery /x-pack/test/accessibility/apps/group3/search_sessions.ts @elastic/kibana-data-discovery -/x-pack/test/api_integration/apis/management/rollup/index_patterns_extensions.js @elastic/kibana-data-discovery +/x-pack/platform/test/api_integration/apis/management/rollup/index_patterns_extensions.js @elastic/kibana-data-discovery /x-pack/platform/test/api_integration/apis/search @elastic/kibana-data-discovery /x-pack/test/examples/search_examples @elastic/kibana-data-discovery /x-pack/test/functional/apps/data_views @elastic/kibana-data-discovery @@ -1429,12 +1429,12 @@ src/platform/plugins/shared/discover/public/context_awareness/profile_providers/ /x-pack/test/functional/page_objects/alert_controls.ts @elastic/obs-ux-management-team # Elastic Stack Monitoring -/x-pack/test/monitoring_api_integration @elastic/stack-monitoring +/x-pack/platform/test/monitoring_api_integration @elastic/stack-monitoring /x-pack/test/functional/page_objects/monitoring_page.ts @elastic/stack-monitoring /x-pack/test/functional/es_archives/monitoring @elastic/stack-monitoring /x-pack/test/functional/services/monitoring @elastic/stack-monitoring /x-pack/test/functional/apps/monitoring @elastic/stack-monitoring -/x-pack/test/api_integration/apis/monitoring @elastic/stack-monitoring +/x-pack/platform/test/api_integration/apis/monitoring @elastic/stack-monitoring /x-pack/platform/test/api_integration/apis/monitoring_collection @elastic/stack-monitoring /x-pack/test/accessibility/apps/group1/kibana_overview.ts @elastic/stack-monitoring /x-pack/test/accessibility/apps/group3/stack_monitoring.ts @elastic/stack-monitoring @@ -2009,7 +2009,7 @@ x-pack/platform/plugins/private/cloud_integrations/cloud_full_story/server/confi /x-pack/test/security_api_integration/ @elastic/kibana-security /x-pack/test/security_functional/ @elastic/kibana-security /x-pack/test/spaces_api_integration/ @elastic/kibana-security -/x-pack/test/saved_object_api_integration/ @elastic/kibana-security +/x-pack/platform/test/saved_object_api_integration/ @elastic/kibana-security /x-pack/test_serverless/**/test_suites/common/platform_security/ @elastic/kibana-security /x-pack/test_serverless/**/test_suites/search/platform_security/ @elastic/kibana-security /x-pack/test_serverless/**/test_suites/observability/platform_security/ @elastic/kibana-security @@ -2113,7 +2113,7 @@ x-pack/platform/plugins/private/cloud_integrations/cloud_full_story/server/confi /x-pack/test_serverless/api_integration/test_suites/search/serverless_search @elastic/search-kibana /x-pack/test_serverless/functional/test_suites/search/ @elastic/search-kibana /x-pack/test_serverless/functional/test_suites/search/config.ts @elastic/search-kibana @elastic/appex-qa -x-pack/test/api_integration/apis/management/index_management/inference_endpoints.ts @elastic/search-kibana +/x-pack/platform/test/api_integration/apis/management/index_management/inference_endpoints.ts @elastic/search-kibana /x-pack/test_serverless/api_integration/test_suites/search @elastic/search-kibana /x-pack/test_serverless/functional/page_objects/svl_api_keys.ts @elastic/search-kibana /x-pack/test_serverless/functional/page_objects/svl_search_* @elastic/search-kibana @@ -2194,7 +2194,7 @@ x-pack/test/api_integration/apis/management/index_management/inference_endpoints /x-pack/test_serverless/functional/test_suites/common/management/landing_page.ts @elastic/kibana-management /x-pack/test_serverless/functional/test_suites/common/dev_tools/ @elastic/kibana-management /x-pack/test_serverless/**/test_suites/common/grok_debugger/ @elastic/kibana-management -/x-pack/test/api_integration/apis/management/ @elastic/kibana-management +/x-pack/platform/test/api_integration/apis/management/ @elastic/kibana-management /x-pack/test/api_integration/deployment_agnostic/apis/management/ @elastic/kibana-management /x-pack/test/api_integration/deployment_agnostic/apis/painless_lab/ @elastic/kibana-management /x-pack/test/functional/apps/rollup_job/ @elastic/kibana-management @@ -2564,7 +2564,7 @@ x-pack/test/security_solution_cypress/cypress/tasks/expandable_flyout @elastic/ ## Security Solution sub teams - security-defend-workflows /x-pack/test/defend_workflows_cypress @elastic/security-defend-workflows -/x-pack/test/api_integration/apis/osquery @elastic/security-defend-workflows +/x-pack/platform/test/api_integration/apis/osquery @elastic/security-defend-workflows /x-pack/solutions/security/plugins/security_solution/public/management/ @elastic/security-defend-workflows /x-pack/solutions/security/plugins/security_solution/public/common/lib/endpoint/ @elastic/security-defend-workflows /x-pack/solutions/security/plugins/security_solution/public/common/components/endpoint/ @elastic/security-defend-workflows @@ -2615,7 +2615,7 @@ x-pack/solutions/security/packages/navigation/src/navigation_tree/entity_analyti x-pack/test/security_solution_api_integration/test_suites/genai @elastic/security-generative-ai ## Security Solution sub teams - Automatic Import -x-pack/test/automatic_import_api_integration @elastic/security-scalability +x-pack/platform/test/automatic_import_api_integration @elastic/security-scalability # Security Defend Workflows - OSQuery Ownership /x-pack/test/osquery_cypress @elastic/security-defend-workflows diff --git a/package.json b/package.json index 4782ffa41199..504efa17ae53 100644 --- a/package.json +++ b/package.json @@ -799,7 +799,7 @@ "@kbn/sample-task-plugin-update-by-query": "link:x-pack/test/task_manager_claimer_update_by_query/plugins/sample_task_plugin_mget", "@kbn/saved-object-export-transforms-plugin": "link:src/platform/test/plugin_functional/plugins/saved_object_export_transforms", "@kbn/saved-object-import-warnings-plugin": "link:src/platform/test/plugin_functional/plugins/saved_object_import_warnings", - "@kbn/saved-object-test-plugin": "link:x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin", + "@kbn/saved-object-test-plugin": "link:x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin", "@kbn/saved-objects-finder-plugin": "link:src/platform/plugins/shared/saved_objects_finder", "@kbn/saved-objects-hidden-from-http-apis-type-plugin": "link:src/platform/test/plugin_functional/plugins/saved_objects_hidden_from_http_apis_type", "@kbn/saved-objects-hidden-type-plugin": "link:src/platform/test/plugin_functional/plugins/saved_objects_hidden_type", diff --git a/packages/kbn-check-mappings-update-cli/current_mappings.json b/packages/kbn-check-mappings-update-cli/current_mappings.json index 063f0e3f6f85..08f862ff517f 100644 --- a/packages/kbn-check-mappings-update-cli/current_mappings.json +++ b/packages/kbn-check-mappings-update-cli/current_mappings.json @@ -4022,4 +4022,4 @@ "dynamic": false, "properties": {} } -} +} \ No newline at end of file diff --git a/src/platform/packages/private/kbn-repo-packages/modern/package.js b/src/platform/packages/private/kbn-repo-packages/modern/package.js index 2b82e95ecb54..f131aee6c853 100644 --- a/src/platform/packages/private/kbn-repo-packages/modern/package.js +++ b/src/platform/packages/private/kbn-repo-packages/modern/package.js @@ -191,7 +191,10 @@ class Package { const dir = this.normalizedRepoRelativeDir; const oss = !dir.startsWith('x-pack/'); const example = dir.startsWith('examples/') || dir.startsWith('x-pack/examples/'); - const testPlugin = dir.startsWith('src/platform/test/') || dir.startsWith('x-pack/test/'); + const testPlugin = + dir.startsWith('src/platform/test/') || + dir.startsWith('x-pack/platform/test') || + dir.startsWith('x-pack/test/'); return { oss, diff --git a/tsconfig.base.json b/tsconfig.base.json index d96e0f60ff68..99ba3a87ed61 100644 --- a/tsconfig.base.json +++ b/tsconfig.base.json @@ -1566,8 +1566,8 @@ "@kbn/saved-object-export-transforms-plugin/*": ["src/platform/test/plugin_functional/plugins/saved_object_export_transforms/*"], "@kbn/saved-object-import-warnings-plugin": ["src/platform/test/plugin_functional/plugins/saved_object_import_warnings"], "@kbn/saved-object-import-warnings-plugin/*": ["src/platform/test/plugin_functional/plugins/saved_object_import_warnings/*"], - "@kbn/saved-object-test-plugin": ["x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin"], - "@kbn/saved-object-test-plugin/*": ["x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/*"], + "@kbn/saved-object-test-plugin": ["x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin"], + "@kbn/saved-object-test-plugin/*": ["x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/*"], "@kbn/saved-objects-finder-plugin": ["src/platform/plugins/shared/saved_objects_finder"], "@kbn/saved-objects-finder-plugin/*": ["src/platform/plugins/shared/saved_objects_finder/*"], "@kbn/saved-objects-hidden-from-http-apis-type-plugin": ["src/platform/test/plugin_functional/plugins/saved_objects_hidden_from_http_apis_type"], diff --git a/x-pack/platform/plugins/private/monitoring/dev_docs/how_to/work_with_packages.md b/x-pack/platform/plugins/private/monitoring/dev_docs/how_to/work_with_packages.md index d273c938942e..b67a0dbc1d0a 100644 --- a/x-pack/platform/plugins/private/monitoring/dev_docs/how_to/work_with_packages.md +++ b/x-pack/platform/plugins/private/monitoring/dev_docs/how_to/work_with_packages.md @@ -149,7 +149,7 @@ See the [elastic-package-test documentation](https://github.com/elastic/elastic- The system tests spawn a full setup (`elastic-package stack up` + `elastic-package service up`), install the package and attach a policy to a running agent to collect live data. This real-world setup can be leveraged to continuously validate future versions of the stack when they are released. Right now the service dependencies are running on 8.5.0 and the tests validate that this version is supported. The plan is to have an automated job that opens a PR validating that the tests are still successful with the latest released version. -On the Stack Monitoring side, we have an API integration test suite running against packages; see https://github.com/elastic/kibana/tree/main/x-pack/test/monitoring_api_integration#readme +On the Stack Monitoring side, we have an API integration test suite running against packages; see https://github.com/elastic/kibana/tree/main/x-pack/platform/test/monitoring_api_integration#readme ## Troubleshooting diff --git a/x-pack/test/api_integration/apis/management/advanced_settings/feature_controls.ts b/x-pack/platform/test/api_integration/apis/management/advanced_settings/feature_controls.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/advanced_settings/feature_controls.ts rename to x-pack/platform/test/api_integration/apis/management/advanced_settings/feature_controls.ts diff --git a/x-pack/test/api_integration/apis/management/advanced_settings/index.ts b/x-pack/platform/test/api_integration/apis/management/advanced_settings/index.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/advanced_settings/index.ts rename to x-pack/platform/test/api_integration/apis/management/advanced_settings/index.ts diff --git a/x-pack/test/api_integration/apis/management/advanced_settings/utils/index.ts b/x-pack/platform/test/api_integration/apis/management/advanced_settings/utils/index.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/advanced_settings/utils/index.ts rename to x-pack/platform/test/api_integration/apis/management/advanced_settings/utils/index.ts diff --git a/x-pack/test/api_integration/apis/management/advanced_settings/utils/retry_if_conflicts.ts b/x-pack/platform/test/api_integration/apis/management/advanced_settings/utils/retry_if_conflicts.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/advanced_settings/utils/retry_if_conflicts.ts rename to x-pack/platform/test/api_integration/apis/management/advanced_settings/utils/retry_if_conflicts.ts diff --git a/x-pack/test/api_integration/apis/management/config.ts b/x-pack/platform/test/api_integration/apis/management/config.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/config.ts rename to x-pack/platform/test/api_integration/apis/management/config.ts diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.helpers.js b/x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.helpers.js similarity index 100% rename from x-pack/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.helpers.js rename to x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.helpers.js diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.js b/x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.js similarity index 100% rename from x-pack/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.js rename to x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.js diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/constants.js b/x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/constants.js similarity index 100% rename from x-pack/test/api_integration/apis/management/cross_cluster_replication/constants.js rename to x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/constants.js diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/fixtures.js b/x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/fixtures.js similarity index 100% rename from x-pack/test/api_integration/apis/management/cross_cluster_replication/fixtures.js rename to x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/fixtures.js diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/follower_indices.helpers.js b/x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/follower_indices.helpers.js similarity index 100% rename from x-pack/test/api_integration/apis/management/cross_cluster_replication/follower_indices.helpers.js rename to x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/follower_indices.helpers.js diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/follower_indices.js b/x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/follower_indices.js similarity index 100% rename from x-pack/test/api_integration/apis/management/cross_cluster_replication/follower_indices.js rename to x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/follower_indices.js diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/index.js b/x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/index.js similarity index 100% rename from x-pack/test/api_integration/apis/management/cross_cluster_replication/index.js rename to x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/index.js diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/lib/elasticsearch.js b/x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/lib/elasticsearch.js similarity index 100% rename from x-pack/test/api_integration/apis/management/cross_cluster_replication/lib/elasticsearch.js rename to x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/lib/elasticsearch.js diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/lib/index.js b/x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/lib/index.js similarity index 100% rename from x-pack/test/api_integration/apis/management/cross_cluster_replication/lib/index.js rename to x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/lib/index.js diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/remote_clusters.helpers.js b/x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/remote_clusters.helpers.js similarity index 100% rename from x-pack/test/api_integration/apis/management/cross_cluster_replication/remote_clusters.helpers.js rename to x-pack/platform/test/api_integration/apis/management/cross_cluster_replication/remote_clusters.helpers.js diff --git a/x-pack/test/api_integration/apis/management/index.js b/x-pack/platform/test/api_integration/apis/management/index.ts similarity index 84% rename from x-pack/test/api_integration/apis/management/index.js rename to x-pack/platform/test/api_integration/apis/management/index.ts index 852348d8d243..dd16f2f2a349 100644 --- a/x-pack/test/api_integration/apis/management/index.js +++ b/x-pack/platform/test/api_integration/apis/management/index.ts @@ -5,7 +5,9 @@ * 2.0. */ -export default function ({ loadTestFile }) { +import type { FtrProviderContext } from '../../ftr_provider_context'; + +export default function ({ loadTestFile }: FtrProviderContext) { describe('management', () => { loadTestFile(require.resolve('./advanced_settings')); loadTestFile(require.resolve('./cross_cluster_replication')); diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/constants.ts b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/constants.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/constants.ts rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/constants.ts diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/fixtures.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/fixtures.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/fixtures.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/fixtures.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/index.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/index.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/index.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/index.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/indices.helpers.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/indices.helpers.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/indices.helpers.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/indices.helpers.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/indices.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/indices.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/indices.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/indices.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/lib/elasticsearch.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/lib/elasticsearch.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/lib/elasticsearch.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/lib/elasticsearch.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/lib/index.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/lib/index.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/lib/index.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/lib/index.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/lib/random.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/lib/random.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/lib/random.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/lib/random.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/lib/utils.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/lib/utils.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/lib/utils.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/lib/utils.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/nodes.helpers.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/nodes.helpers.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/nodes.helpers.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/nodes.helpers.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/nodes.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/nodes.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/nodes.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/nodes.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/policies.helpers.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/policies.helpers.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/policies.helpers.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/policies.helpers.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/policies.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/policies.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/policies.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/policies.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/snapshot_policies.helpers.ts b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/snapshot_policies.helpers.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/snapshot_policies.helpers.ts rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/snapshot_policies.helpers.ts diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/snapshot_policies.ts b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/snapshot_policies.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/snapshot_policies.ts rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/snapshot_policies.ts diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/snapshot_repositories.helpers.ts b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/snapshot_repositories.helpers.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/snapshot_repositories.helpers.ts rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/snapshot_repositories.helpers.ts diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/snapshot_repositories.ts b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/snapshot_repositories.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/snapshot_repositories.ts rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/snapshot_repositories.ts diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/templates.helpers.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/templates.helpers.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/templates.helpers.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/templates.helpers.js diff --git a/x-pack/test/api_integration/apis/management/index_lifecycle_management/templates.js b/x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/templates.js similarity index 100% rename from x-pack/test/api_integration/apis/management/index_lifecycle_management/templates.js rename to x-pack/platform/test/api_integration/apis/management/index_lifecycle_management/templates.js diff --git a/x-pack/test/api_integration/apis/management/index_management/cluster_nodes.ts b/x-pack/platform/test/api_integration/apis/management/index_management/cluster_nodes.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/cluster_nodes.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/cluster_nodes.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/component_templates.ts b/x-pack/platform/test/api_integration/apis/management/index_management/component_templates.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/component_templates.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/component_templates.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/constants.ts b/x-pack/platform/test/api_integration/apis/management/index_management/constants.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/constants.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/constants.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/create_enrich_policy.ts b/x-pack/platform/test/api_integration/apis/management/index_management/create_enrich_policy.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/create_enrich_policy.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/create_enrich_policy.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/create_index.ts b/x-pack/platform/test/api_integration/apis/management/index_management/create_index.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/create_index.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/create_index.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/data_enrichers/ilm.ts b/x-pack/platform/test/api_integration/apis/management/index_management/data_enrichers/ilm.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/data_enrichers/ilm.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/data_enrichers/ilm.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/data_enrichers/index.ts b/x-pack/platform/test/api_integration/apis/management/index_management/data_enrichers/index.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/data_enrichers/index.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/data_enrichers/index.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/data_streams.ts b/x-pack/platform/test/api_integration/apis/management/index_management/data_streams.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/data_streams.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/data_streams.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/disabled_data_enrichers/config.ts b/x-pack/platform/test/api_integration/apis/management/index_management/disabled_data_enrichers/config.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/disabled_data_enrichers/config.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/disabled_data_enrichers/config.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/disabled_data_enrichers/index.ts b/x-pack/platform/test/api_integration/apis/management/index_management/disabled_data_enrichers/index.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/disabled_data_enrichers/index.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/disabled_data_enrichers/index.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/disabled_data_enrichers/indices.ts b/x-pack/platform/test/api_integration/apis/management/index_management/disabled_data_enrichers/indices.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/disabled_data_enrichers/indices.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/disabled_data_enrichers/indices.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/enrich_policies.ts b/x-pack/platform/test/api_integration/apis/management/index_management/enrich_policies.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/enrich_policies.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/enrich_policies.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/index.ts b/x-pack/platform/test/api_integration/apis/management/index_management/index.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/index.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/index.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/index_details.ts b/x-pack/platform/test/api_integration/apis/management/index_management/index_details.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/index_details.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/index_details.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/indices.ts b/x-pack/platform/test/api_integration/apis/management/index_management/indices.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/indices.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/indices.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/cluster_nodes.api.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/cluster_nodes.api.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/cluster_nodes.api.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/cluster_nodes.api.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/component_template.helpers.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/component_template.helpers.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/component_template.helpers.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/component_template.helpers.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/component_templates.api.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/component_templates.api.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/component_templates.api.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/component_templates.api.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/datastreams.helpers.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/datastreams.helpers.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/datastreams.helpers.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/datastreams.helpers.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/enrich_policies.api.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/enrich_policies.api.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/enrich_policies.api.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/enrich_policies.api.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/enrich_policies.helpers.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/enrich_policies.helpers.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/enrich_policies.helpers.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/enrich_policies.helpers.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/index.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/index.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/index.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/index.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/indices.api.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/indices.api.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/indices.api.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/indices.api.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/indices.helpers.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/indices.helpers.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/indices.helpers.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/indices.helpers.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/mappings.api.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/mappings.api.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/mappings.api.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/mappings.api.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/random.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/random.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/random.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/random.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/settings.api.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/settings.api.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/settings.api.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/settings.api.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/templates.api.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/templates.api.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/templates.api.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/templates.api.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/lib/templates.helpers.ts b/x-pack/platform/test/api_integration/apis/management/index_management/lib/templates.helpers.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/lib/templates.helpers.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/lib/templates.helpers.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/mapping.ts b/x-pack/platform/test/api_integration/apis/management/index_management/mapping.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/mapping.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/mapping.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/searchprofiler.ts b/x-pack/platform/test/api_integration/apis/management/index_management/searchprofiler.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/searchprofiler.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/searchprofiler.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/settings.ts b/x-pack/platform/test/api_integration/apis/management/index_management/settings.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/settings.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/settings.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/stats.ts b/x-pack/platform/test/api_integration/apis/management/index_management/stats.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/stats.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/stats.ts diff --git a/x-pack/test/api_integration/apis/management/index_management/templates.ts b/x-pack/platform/test/api_integration/apis/management/index_management/templates.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/index_management/templates.ts rename to x-pack/platform/test/api_integration/apis/management/index_management/templates.ts diff --git a/x-pack/test/api_integration/apis/management/ingest_pipelines/databases.ts b/x-pack/platform/test/api_integration/apis/management/ingest_pipelines/databases.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/ingest_pipelines/databases.ts rename to x-pack/platform/test/api_integration/apis/management/ingest_pipelines/databases.ts diff --git a/x-pack/test/api_integration/apis/management/ingest_pipelines/index.ts b/x-pack/platform/test/api_integration/apis/management/ingest_pipelines/index.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/ingest_pipelines/index.ts rename to x-pack/platform/test/api_integration/apis/management/ingest_pipelines/index.ts diff --git a/x-pack/test/api_integration/apis/management/ingest_pipelines/parse_csv.ts b/x-pack/platform/test/api_integration/apis/management/ingest_pipelines/parse_csv.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/ingest_pipelines/parse_csv.ts rename to x-pack/platform/test/api_integration/apis/management/ingest_pipelines/parse_csv.ts diff --git a/x-pack/test/api_integration/apis/management/ingest_pipelines/pipeline_mappings.ts b/x-pack/platform/test/api_integration/apis/management/ingest_pipelines/pipeline_mappings.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/ingest_pipelines/pipeline_mappings.ts rename to x-pack/platform/test/api_integration/apis/management/ingest_pipelines/pipeline_mappings.ts diff --git a/x-pack/test/api_integration/apis/management/remote_clusters/constants.js b/x-pack/platform/test/api_integration/apis/management/remote_clusters/constants.js similarity index 100% rename from x-pack/test/api_integration/apis/management/remote_clusters/constants.js rename to x-pack/platform/test/api_integration/apis/management/remote_clusters/constants.js diff --git a/x-pack/test/api_integration/apis/management/remote_clusters/index.js b/x-pack/platform/test/api_integration/apis/management/remote_clusters/index.js similarity index 100% rename from x-pack/test/api_integration/apis/management/remote_clusters/index.js rename to x-pack/platform/test/api_integration/apis/management/remote_clusters/index.js diff --git a/x-pack/test/api_integration/apis/management/remote_clusters/remote_clusters.js b/x-pack/platform/test/api_integration/apis/management/remote_clusters/remote_clusters.js similarity index 100% rename from x-pack/test/api_integration/apis/management/remote_clusters/remote_clusters.js rename to x-pack/platform/test/api_integration/apis/management/remote_clusters/remote_clusters.js diff --git a/x-pack/test/api_integration/apis/management/rollup/constants.js b/x-pack/platform/test/api_integration/apis/management/rollup/constants.js similarity index 100% rename from x-pack/test/api_integration/apis/management/rollup/constants.js rename to x-pack/platform/test/api_integration/apis/management/rollup/constants.js diff --git a/x-pack/test/api_integration/apis/management/rollup/index.js b/x-pack/platform/test/api_integration/apis/management/rollup/index.js similarity index 100% rename from x-pack/test/api_integration/apis/management/rollup/index.js rename to x-pack/platform/test/api_integration/apis/management/rollup/index.js diff --git a/x-pack/test/api_integration/apis/management/rollup/index_patterns_extensions.js b/x-pack/platform/test/api_integration/apis/management/rollup/index_patterns_extensions.js similarity index 100% rename from x-pack/test/api_integration/apis/management/rollup/index_patterns_extensions.js rename to x-pack/platform/test/api_integration/apis/management/rollup/index_patterns_extensions.js diff --git a/x-pack/test/api_integration/apis/management/rollup/lib/es_index.js b/x-pack/platform/test/api_integration/apis/management/rollup/lib/es_index.js similarity index 100% rename from x-pack/test/api_integration/apis/management/rollup/lib/es_index.js rename to x-pack/platform/test/api_integration/apis/management/rollup/lib/es_index.js diff --git a/x-pack/test/api_integration/apis/management/rollup/lib/index.js b/x-pack/platform/test/api_integration/apis/management/rollup/lib/index.js similarity index 100% rename from x-pack/test/api_integration/apis/management/rollup/lib/index.js rename to x-pack/platform/test/api_integration/apis/management/rollup/lib/index.js diff --git a/x-pack/test/api_integration/apis/management/rollup/lib/random.js b/x-pack/platform/test/api_integration/apis/management/rollup/lib/random.js similarity index 100% rename from x-pack/test/api_integration/apis/management/rollup/lib/random.js rename to x-pack/platform/test/api_integration/apis/management/rollup/lib/random.js diff --git a/x-pack/test/api_integration/apis/management/rollup/lib/utils.js b/x-pack/platform/test/api_integration/apis/management/rollup/lib/utils.js similarity index 100% rename from x-pack/test/api_integration/apis/management/rollup/lib/utils.js rename to x-pack/platform/test/api_integration/apis/management/rollup/lib/utils.js diff --git a/x-pack/test/api_integration/apis/management/rollup/rollup.js b/x-pack/platform/test/api_integration/apis/management/rollup/rollup.js similarity index 100% rename from x-pack/test/api_integration/apis/management/rollup/rollup.js rename to x-pack/platform/test/api_integration/apis/management/rollup/rollup.js diff --git a/x-pack/test/api_integration/apis/management/rollup/rollup.test_helpers.js b/x-pack/platform/test/api_integration/apis/management/rollup/rollup.test_helpers.js similarity index 100% rename from x-pack/test/api_integration/apis/management/rollup/rollup.test_helpers.js rename to x-pack/platform/test/api_integration/apis/management/rollup/rollup.test_helpers.js diff --git a/x-pack/test/api_integration/apis/management/rollup/rollup_search.js b/x-pack/platform/test/api_integration/apis/management/rollup/rollup_search.js similarity index 100% rename from x-pack/test/api_integration/apis/management/rollup/rollup_search.js rename to x-pack/platform/test/api_integration/apis/management/rollup/rollup_search.js diff --git a/x-pack/test/api_integration/apis/management/snapshot_restore/index.ts b/x-pack/platform/test/api_integration/apis/management/snapshot_restore/index.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/snapshot_restore/index.ts rename to x-pack/platform/test/api_integration/apis/management/snapshot_restore/index.ts diff --git a/x-pack/test/api_integration/apis/management/snapshot_restore/lib/elasticsearch.ts b/x-pack/platform/test/api_integration/apis/management/snapshot_restore/lib/elasticsearch.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/snapshot_restore/lib/elasticsearch.ts rename to x-pack/platform/test/api_integration/apis/management/snapshot_restore/lib/elasticsearch.ts diff --git a/x-pack/test/api_integration/apis/management/snapshot_restore/lib/index.ts b/x-pack/platform/test/api_integration/apis/management/snapshot_restore/lib/index.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/snapshot_restore/lib/index.ts rename to x-pack/platform/test/api_integration/apis/management/snapshot_restore/lib/index.ts diff --git a/x-pack/test/api_integration/apis/management/snapshot_restore/policies.ts b/x-pack/platform/test/api_integration/apis/management/snapshot_restore/policies.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/snapshot_restore/policies.ts rename to x-pack/platform/test/api_integration/apis/management/snapshot_restore/policies.ts diff --git a/x-pack/test/api_integration/apis/management/snapshot_restore/repositories.ts b/x-pack/platform/test/api_integration/apis/management/snapshot_restore/repositories.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/snapshot_restore/repositories.ts rename to x-pack/platform/test/api_integration/apis/management/snapshot_restore/repositories.ts diff --git a/x-pack/test/api_integration/apis/management/snapshot_restore/snapshots.ts b/x-pack/platform/test/api_integration/apis/management/snapshot_restore/snapshots.ts similarity index 100% rename from x-pack/test/api_integration/apis/management/snapshot_restore/snapshots.ts rename to x-pack/platform/test/api_integration/apis/management/snapshot_restore/snapshots.ts diff --git a/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_empty.json b/x-pack/platform/test/api_integration/apis/monitoring/_health/fixtures/response_empty.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_empty.json rename to x-pack/platform/test/api_integration/apis/monitoring/_health/fixtures/response_empty.json diff --git a/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_beats.js b/x-pack/platform/test/api_integration/apis/monitoring/_health/fixtures/response_es_beats.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_beats.js rename to x-pack/platform/test/api_integration/apis/monitoring/_health/fixtures/response_es_beats.js diff --git a/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_package.js b/x-pack/platform/test/api_integration/apis/monitoring/_health/fixtures/response_es_package.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_package.js rename to x-pack/platform/test/api_integration/apis/monitoring/_health/fixtures/response_es_package.js diff --git a/x-pack/test/api_integration/apis/monitoring/_health/index.js b/x-pack/platform/test/api_integration/apis/monitoring/_health/index.js similarity index 89% rename from x-pack/test/api_integration/apis/monitoring/_health/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/_health/index.js index ba7ee0378e7a..27a2f171954f 100644 --- a/x-pack/test/api_integration/apis/monitoring/_health/index.js +++ b/x-pack/platform/test/api_integration/apis/monitoring/_health/index.js @@ -15,9 +15,9 @@ import { esBeatsResponse } from './fixtures/response_es_beats'; import { esPackageResponse } from './fixtures/response_es_package'; const ELASTICSEARCH_PACKAGE_ARCHIVE = - 'x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error'; + 'x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error'; const METRICBEAT_ARCHIVE = - 'x-pack/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8'; + 'x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8'; export default function ({ getService }) { const supertest = getService('supertest'); @@ -41,8 +41,8 @@ export default function ({ getService }) { describe('with metricbeat data', () => { const archives = [ - 'x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_es_8', - 'x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_beats_8', + 'x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/monitoring_es_8', + 'x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/monitoring_beats_8', METRICBEAT_ARCHIVE, ]; const { setup, tearDown } = getLifecycleMethods(getService); diff --git a/x-pack/test/api_integration/apis/monitoring/apm/fixtures/cluster.json b/x-pack/platform/test/api_integration/apis/monitoring/apm/fixtures/cluster.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/apm/fixtures/cluster.json rename to x-pack/platform/test/api_integration/apis/monitoring/apm/fixtures/cluster.json diff --git a/x-pack/test/api_integration/apis/monitoring/apm/fixtures/instance.json b/x-pack/platform/test/api_integration/apis/monitoring/apm/fixtures/instance.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/apm/fixtures/instance.json rename to x-pack/platform/test/api_integration/apis/monitoring/apm/fixtures/instance.json diff --git a/x-pack/test/api_integration/apis/monitoring/apm/index.js b/x-pack/platform/test/api_integration/apis/monitoring/apm/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/apm/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/apm/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/apm/instance.js b/x-pack/platform/test/api_integration/apis/monitoring/apm/instance.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/apm/instance.js rename to x-pack/platform/test/api_integration/apis/monitoring/apm/instance.js diff --git a/x-pack/test/api_integration/apis/monitoring/apm/instances.js b/x-pack/platform/test/api_integration/apis/monitoring/apm/instances.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/apm/instances.js rename to x-pack/platform/test/api_integration/apis/monitoring/apm/instances.js diff --git a/x-pack/test/api_integration/apis/monitoring/apm/overview.js b/x-pack/platform/test/api_integration/apis/monitoring/apm/overview.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/apm/overview.js rename to x-pack/platform/test/api_integration/apis/monitoring/apm/overview.js diff --git a/x-pack/test/api_integration/apis/monitoring/beats/detail.js b/x-pack/platform/test/api_integration/apis/monitoring/beats/detail.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/beats/detail.js rename to x-pack/platform/test/api_integration/apis/monitoring/beats/detail.js diff --git a/x-pack/test/api_integration/apis/monitoring/beats/fixtures/cluster.json b/x-pack/platform/test/api_integration/apis/monitoring/beats/fixtures/cluster.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/beats/fixtures/cluster.json rename to x-pack/platform/test/api_integration/apis/monitoring/beats/fixtures/cluster.json diff --git a/x-pack/test/api_integration/apis/monitoring/beats/fixtures/detail.json b/x-pack/platform/test/api_integration/apis/monitoring/beats/fixtures/detail.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/beats/fixtures/detail.json rename to x-pack/platform/test/api_integration/apis/monitoring/beats/fixtures/detail.json diff --git a/x-pack/test/api_integration/apis/monitoring/beats/index.js b/x-pack/platform/test/api_integration/apis/monitoring/beats/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/beats/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/beats/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/beats/list.js b/x-pack/platform/test/api_integration/apis/monitoring/beats/list.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/beats/list.js rename to x-pack/platform/test/api_integration/apis/monitoring/beats/list.js diff --git a/x-pack/test/api_integration/apis/monitoring/beats/overview.js b/x-pack/platform/test/api_integration/apis/monitoring/beats/overview.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/beats/overview.js rename to x-pack/platform/test/api_integration/apis/monitoring/beats/overview.js diff --git a/x-pack/test/api_integration/apis/monitoring/cluster/fixtures/multicluster.json b/x-pack/platform/test/api_integration/apis/monitoring/cluster/fixtures/multicluster.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/cluster/fixtures/multicluster.json rename to x-pack/platform/test/api_integration/apis/monitoring/cluster/fixtures/multicluster.json diff --git a/x-pack/test/api_integration/apis/monitoring/cluster/fixtures/overview.json b/x-pack/platform/test/api_integration/apis/monitoring/cluster/fixtures/overview.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/cluster/fixtures/overview.json rename to x-pack/platform/test/api_integration/apis/monitoring/cluster/fixtures/overview.json diff --git a/x-pack/test/api_integration/apis/monitoring/cluster/index.js b/x-pack/platform/test/api_integration/apis/monitoring/cluster/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/cluster/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/cluster/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/cluster/list.js b/x-pack/platform/test/api_integration/apis/monitoring/cluster/list.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/cluster/list.js rename to x-pack/platform/test/api_integration/apis/monitoring/cluster/list.js diff --git a/x-pack/test/api_integration/apis/monitoring/cluster/list_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/cluster/list_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/cluster/list_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/cluster/list_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/cluster/overview.js b/x-pack/platform/test/api_integration/apis/monitoring/cluster/overview.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/cluster/overview.js rename to x-pack/platform/test/api_integration/apis/monitoring/cluster/overview.js diff --git a/x-pack/test/api_integration/apis/monitoring/cluster/overview_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/cluster/overview_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/cluster/overview_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/cluster/overview_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/common/index.js b/x-pack/platform/test/api_integration/apis/monitoring/common/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/common/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/common/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/common/mappings_exist.js b/x-pack/platform/test/api_integration/apis/monitoring/common/mappings_exist.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/common/mappings_exist.js rename to x-pack/platform/test/api_integration/apis/monitoring/common/mappings_exist.js diff --git a/x-pack/test/api_integration/apis/monitoring/config.ts b/x-pack/platform/test/api_integration/apis/monitoring/config.ts similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/config.ts rename to x-pack/platform/test/api_integration/apis/monitoring/config.ts diff --git a/x-pack/test/api_integration/apis/monitoring/data_stream.ts b/x-pack/platform/test/api_integration/apis/monitoring/data_stream.ts similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/data_stream.ts rename to x-pack/platform/test/api_integration/apis/monitoring/data_stream.ts diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/ccr.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/ccr.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/ccr_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/ccr_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr_shard.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/ccr_shard.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr_shard.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/ccr_shard.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr_shard_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/ccr_shard_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr_shard_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/ccr_shard_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/ccr.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/ccr.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/ccr.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/ccr.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/ccr_shard.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/ccr_shard.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/ccr_shard.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/ccr_shard.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/index_detail.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/index_detail.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/index_detail.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/index_detail.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/index_detail_advanced.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/index_detail_advanced.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/index_detail_advanced.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/index_detail_advanced.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_red_cluster.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_red_cluster.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_red_cluster.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_red_cluster.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_red_cluster_all.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_red_cluster_all.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_red_cluster_all.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_red_cluster_all.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_shards_relocating.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_shards_relocating.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_shards_relocating.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_shards_relocating.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_shards_relocating_all.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_shards_relocating_all.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_shards_relocating_all.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/indices_shards_relocating_all.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/node_detail.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/node_detail.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/node_detail.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/node_detail.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/node_detail_advanced.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/node_detail_advanced.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/node_detail_advanced.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/node_detail_advanced.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_cgroup.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_cgroup.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_cgroup.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_cgroup.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_green.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_green.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_green.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_green.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_pagination.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_pagination.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_pagination.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_pagination.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_red.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_red.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_red.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/nodes_listing_red.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_green_platinum.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_green_platinum.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_green_platinum.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_green_platinum.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_red_platinum.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_red_platinum.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_red_platinum.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_red_platinum.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_shards_relocating.json b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_shards_relocating.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_shards_relocating.json rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/fixtures/overview_shards_relocating.json diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/index.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/index_detail.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/index_detail.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/index_detail.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/index_detail.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/index_detail_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/index_detail_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/index_detail_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/index_detail_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/indices.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/indices.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/indices.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/indices.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/node_detail.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/node_detail.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/node_detail_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/node_detail_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/nodes.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/nodes.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/nodes.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/nodes.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/nodes_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/nodes_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/nodes_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/nodes_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/overview.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/overview.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/overview.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/overview.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/overview_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/overview_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch/overview_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch/overview_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_cluster.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch_settings/check_cluster.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_cluster.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch_settings/check_cluster.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_nodes.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch_settings/check_nodes.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_nodes.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch_settings/check_nodes.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/index.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch_settings/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch_settings/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_enabled.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_enabled.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_enabled.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_enabled.js diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_interval.js b/x-pack/platform/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_interval.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_interval.js rename to x-pack/platform/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_interval.js diff --git a/x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/data.json.gz b/x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/data.json.gz similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/data.json.gz rename to x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/data.json.gz diff --git a/x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/mappings.json b/x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/mappings.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/mappings.json rename to x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/mappings.json diff --git a/x-pack/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8/data.json.gz b/x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8/data.json.gz similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8/data.json.gz rename to x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8/data.json.gz diff --git a/x-pack/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8/mappings.json b/x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8/mappings.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8/mappings.json rename to x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8/mappings.json diff --git a/x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_beats_8/data.json.gz b/x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/monitoring_beats_8/data.json.gz similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_beats_8/data.json.gz rename to x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/monitoring_beats_8/data.json.gz diff --git a/x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_es_8/data.json.gz b/x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/monitoring_es_8/data.json.gz similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_es_8/data.json.gz rename to x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/monitoring_es_8/data.json.gz diff --git a/x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_kibana_8/data.json.gz b/x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/monitoring_kibana_8/data.json.gz similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_kibana_8/data.json.gz rename to x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/monitoring_kibana_8/data.json.gz diff --git a/x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_logstash_standalone_8/data.json.gz b/x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/monitoring_logstash_standalone_8/data.json.gz similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_logstash_standalone_8/data.json.gz rename to x-pack/platform/test/api_integration/apis/monitoring/es_archives/_health/monitoring_logstash_standalone_8/data.json.gz diff --git a/x-pack/test/api_integration/apis/monitoring/index.js b/x-pack/platform/test/api_integration/apis/monitoring/index.ts similarity index 87% rename from x-pack/test/api_integration/apis/monitoring/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/index.ts index ebbf9c3af16e..89e1d92937b6 100644 --- a/x-pack/test/api_integration/apis/monitoring/index.js +++ b/x-pack/platform/test/api_integration/apis/monitoring/index.ts @@ -5,7 +5,9 @@ * 2.0. */ -export default function ({ loadTestFile }) { +import { FtrProviderContext } from '../../ftr_provider_context'; + +export default function ({ loadTestFile }: FtrProviderContext) { describe('Monitoring', () => { loadTestFile(require.resolve('./apm')); loadTestFile(require.resolve('./beats')); diff --git a/x-pack/test/api_integration/apis/monitoring/kibana/fixtures/instance.json b/x-pack/platform/test/api_integration/apis/monitoring/kibana/fixtures/instance.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/kibana/fixtures/instance.json rename to x-pack/platform/test/api_integration/apis/monitoring/kibana/fixtures/instance.json diff --git a/x-pack/test/api_integration/apis/monitoring/kibana/fixtures/listing.json b/x-pack/platform/test/api_integration/apis/monitoring/kibana/fixtures/listing.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/kibana/fixtures/listing.json rename to x-pack/platform/test/api_integration/apis/monitoring/kibana/fixtures/listing.json diff --git a/x-pack/test/api_integration/apis/monitoring/kibana/fixtures/overview.json b/x-pack/platform/test/api_integration/apis/monitoring/kibana/fixtures/overview.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/kibana/fixtures/overview.json rename to x-pack/platform/test/api_integration/apis/monitoring/kibana/fixtures/overview.json diff --git a/x-pack/test/api_integration/apis/monitoring/kibana/index.js b/x-pack/platform/test/api_integration/apis/monitoring/kibana/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/kibana/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/kibana/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/kibana/instance.js b/x-pack/platform/test/api_integration/apis/monitoring/kibana/instance.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/kibana/instance.js rename to x-pack/platform/test/api_integration/apis/monitoring/kibana/instance.js diff --git a/x-pack/test/api_integration/apis/monitoring/kibana/listing.js b/x-pack/platform/test/api_integration/apis/monitoring/kibana/listing.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/kibana/listing.js rename to x-pack/platform/test/api_integration/apis/monitoring/kibana/listing.js diff --git a/x-pack/test/api_integration/apis/monitoring/kibana/overview.js b/x-pack/platform/test/api_integration/apis/monitoring/kibana/overview.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/kibana/overview.js rename to x-pack/platform/test/api_integration/apis/monitoring/kibana/overview.js diff --git a/x-pack/test/api_integration/apis/monitoring/logs/cluster.js b/x-pack/platform/test/api_integration/apis/monitoring/logs/cluster.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logs/cluster.js rename to x-pack/platform/test/api_integration/apis/monitoring/logs/cluster.js diff --git a/x-pack/test/api_integration/apis/monitoring/logs/fixtures/cluster.json b/x-pack/platform/test/api_integration/apis/monitoring/logs/fixtures/cluster.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logs/fixtures/cluster.json rename to x-pack/platform/test/api_integration/apis/monitoring/logs/fixtures/cluster.json diff --git a/x-pack/test/api_integration/apis/monitoring/logs/fixtures/index_detail.json b/x-pack/platform/test/api_integration/apis/monitoring/logs/fixtures/index_detail.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logs/fixtures/index_detail.json rename to x-pack/platform/test/api_integration/apis/monitoring/logs/fixtures/index_detail.json diff --git a/x-pack/test/api_integration/apis/monitoring/logs/fixtures/multiple_clusters.json b/x-pack/platform/test/api_integration/apis/monitoring/logs/fixtures/multiple_clusters.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logs/fixtures/multiple_clusters.json rename to x-pack/platform/test/api_integration/apis/monitoring/logs/fixtures/multiple_clusters.json diff --git a/x-pack/test/api_integration/apis/monitoring/logs/fixtures/node_detail.json b/x-pack/platform/test/api_integration/apis/monitoring/logs/fixtures/node_detail.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logs/fixtures/node_detail.json rename to x-pack/platform/test/api_integration/apis/monitoring/logs/fixtures/node_detail.json diff --git a/x-pack/test/api_integration/apis/monitoring/logs/index.js b/x-pack/platform/test/api_integration/apis/monitoring/logs/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logs/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/logs/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/logs/index_detail.js b/x-pack/platform/test/api_integration/apis/monitoring/logs/index_detail.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logs/index_detail.js rename to x-pack/platform/test/api_integration/apis/monitoring/logs/index_detail.js diff --git a/x-pack/test/api_integration/apis/monitoring/logs/multiple_clusters.js b/x-pack/platform/test/api_integration/apis/monitoring/logs/multiple_clusters.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logs/multiple_clusters.js rename to x-pack/platform/test/api_integration/apis/monitoring/logs/multiple_clusters.js diff --git a/x-pack/test/api_integration/apis/monitoring/logs/node_detail.js b/x-pack/platform/test/api_integration/apis/monitoring/logs/node_detail.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logs/node_detail.js rename to x-pack/platform/test/api_integration/apis/monitoring/logs/node_detail.js diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/fixtures/multicluster_pipelines.json b/x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/multicluster_pipelines.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/fixtures/multicluster_pipelines.json rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/multicluster_pipelines.json diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/fixtures/node_detail.json b/x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/node_detail.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/fixtures/node_detail.json rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/node_detail.json diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/fixtures/node_detail_advanced.json b/x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/node_detail_advanced.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/fixtures/node_detail_advanced.json rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/node_detail_advanced.json diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/fixtures/nodes.json b/x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/nodes.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/fixtures/nodes.json rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/nodes.json diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/fixtures/overview.json b/x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/overview.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/fixtures/overview.json rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/overview.json diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/fixtures/pipelines.json b/x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/pipelines.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/fixtures/pipelines.json rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/fixtures/pipelines.json diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/index.js b/x-pack/platform/test/api_integration/apis/monitoring/logstash/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/multicluster_pipelines.js b/x-pack/platform/test/api_integration/apis/monitoring/logstash/multicluster_pipelines.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/multicluster_pipelines.js rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/multicluster_pipelines.js diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/node_detail.js b/x-pack/platform/test/api_integration/apis/monitoring/logstash/node_detail.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/node_detail.js rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/node_detail.js diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/nodes.js b/x-pack/platform/test/api_integration/apis/monitoring/logstash/nodes.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/nodes.js rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/nodes.js diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/overview.js b/x-pack/platform/test/api_integration/apis/monitoring/logstash/overview.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/overview.js rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/overview.js diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/pipelines.js b/x-pack/platform/test/api_integration/apis/monitoring/logstash/pipelines.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/logstash/pipelines.js rename to x-pack/platform/test/api_integration/apis/monitoring/logstash/pipelines.js diff --git a/x-pack/test/api_integration/apis/monitoring/normalize_data_type_differences.ts b/x-pack/platform/test/api_integration/apis/monitoring/normalize_data_type_differences.ts similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/normalize_data_type_differences.ts rename to x-pack/platform/test/api_integration/apis/monitoring/normalize_data_type_differences.ts diff --git a/x-pack/test/api_integration/apis/monitoring/set_indices_found.tsx b/x-pack/platform/test/api_integration/apis/monitoring/set_indices_found.tsx similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/set_indices_found.tsx rename to x-pack/platform/test/api_integration/apis/monitoring/set_indices_found.tsx diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/ccs.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/ccs.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/ccs.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/ccs.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/detect_apm.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/detect_apm.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/detect_apm.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/detect_apm.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/detect_beats.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/detect_beats.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/detect_beats.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/detect_beats.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/detect_beats_management.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/detect_beats_management.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/detect_beats_management.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/detect_beats_management.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/detect_logstash.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/detect_logstash.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/detect_logstash.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/detect_logstash.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/detect_logstash_management.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/detect_logstash_management.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/detect_logstash_management.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/detect_logstash_management.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/es_and_kibana.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/es_and_kibana.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/es_and_kibana.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/es_and_kibana.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_exclusive.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_exclusive.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_exclusive.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_exclusive.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_exclusive_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_exclusive_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_exclusive_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_exclusive_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/es_and_kibana_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_apm.json b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_apm.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_apm.json rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_apm.json diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_beats.json b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_beats.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_beats.json rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_beats.json diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_beats_management.json b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_beats_management.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_beats_management.json rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_beats_management.json diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_logstash.json b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_logstash.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_logstash.json rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_logstash.json diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_logstash_management.json b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_logstash_management.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_logstash_management.json rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/detect_logstash_management.json diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/es_and_kibana_exclusive_mb.json b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/es_and_kibana_exclusive_mb.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/es_and_kibana_exclusive_mb.json rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/es_and_kibana_exclusive_mb.json diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/es_and_kibana_mb.json b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/es_and_kibana_mb.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/es_and_kibana_mb.json rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/es_and_kibana_mb.json diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/kibana_exclusive_mb.json b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/kibana_exclusive_mb.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/kibana_exclusive_mb.json rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/kibana_exclusive_mb.json diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/kibana_mb.json b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/kibana_mb.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/fixtures/kibana_mb.json rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/fixtures/kibana_mb.json diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/index.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/kibana.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/kibana.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/kibana.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/kibana.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/kibana_exclusive.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/kibana_exclusive.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/kibana_exclusive.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/kibana_exclusive.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/kibana_exclusive_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/kibana_exclusive_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/kibana_exclusive_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/kibana_exclusive_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/kibana_mb.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/kibana_mb.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/kibana_mb.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/kibana_mb.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/collection/security.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/collection/security.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/collection/security.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/collection/security.js diff --git a/x-pack/test/api_integration/apis/monitoring/setup/index.js b/x-pack/platform/test/api_integration/apis/monitoring/setup/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/setup/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/setup/index.js diff --git a/x-pack/test/api_integration/apis/monitoring/standalone_cluster/cluster.js b/x-pack/platform/test/api_integration/apis/monitoring/standalone_cluster/cluster.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/standalone_cluster/cluster.js rename to x-pack/platform/test/api_integration/apis/monitoring/standalone_cluster/cluster.js diff --git a/x-pack/test/api_integration/apis/monitoring/standalone_cluster/clusters.js b/x-pack/platform/test/api_integration/apis/monitoring/standalone_cluster/clusters.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/standalone_cluster/clusters.js rename to x-pack/platform/test/api_integration/apis/monitoring/standalone_cluster/clusters.js diff --git a/x-pack/test/api_integration/apis/monitoring/standalone_cluster/fixtures/cluster.json b/x-pack/platform/test/api_integration/apis/monitoring/standalone_cluster/fixtures/cluster.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/standalone_cluster/fixtures/cluster.json rename to x-pack/platform/test/api_integration/apis/monitoring/standalone_cluster/fixtures/cluster.json diff --git a/x-pack/test/api_integration/apis/monitoring/standalone_cluster/fixtures/clusters.json b/x-pack/platform/test/api_integration/apis/monitoring/standalone_cluster/fixtures/clusters.json similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/standalone_cluster/fixtures/clusters.json rename to x-pack/platform/test/api_integration/apis/monitoring/standalone_cluster/fixtures/clusters.json diff --git a/x-pack/test/api_integration/apis/monitoring/standalone_cluster/index.js b/x-pack/platform/test/api_integration/apis/monitoring/standalone_cluster/index.js similarity index 100% rename from x-pack/test/api_integration/apis/monitoring/standalone_cluster/index.js rename to x-pack/platform/test/api_integration/apis/monitoring/standalone_cluster/index.js diff --git a/x-pack/test/api_integration/apis/osquery/config.ts b/x-pack/platform/test/api_integration/apis/osquery/config.ts similarity index 100% rename from x-pack/test/api_integration/apis/osquery/config.ts rename to x-pack/platform/test/api_integration/apis/osquery/config.ts diff --git a/x-pack/test/api_integration/apis/osquery/index.js b/x-pack/platform/test/api_integration/apis/osquery/index.ts similarity index 72% rename from x-pack/test/api_integration/apis/osquery/index.js rename to x-pack/platform/test/api_integration/apis/osquery/index.ts index afe684aa9bd6..0af0b2d75fbc 100644 --- a/x-pack/test/api_integration/apis/osquery/index.js +++ b/x-pack/platform/test/api_integration/apis/osquery/index.ts @@ -5,7 +5,9 @@ * 2.0. */ -export default function ({ loadTestFile }) { +import { FtrProviderContext } from '../../ftr_provider_context'; + +export default function ({ loadTestFile }: FtrProviderContext) { describe('Osquery Endpoints', () => { loadTestFile(require.resolve('./packs')); }); diff --git a/x-pack/test/api_integration/apis/osquery/packs.ts b/x-pack/platform/test/api_integration/apis/osquery/packs.ts similarity index 100% rename from x-pack/test/api_integration/apis/osquery/packs.ts rename to x-pack/platform/test/api_integration/apis/osquery/packs.ts diff --git a/x-pack/platform/test/api_integration/services/index.ts b/x-pack/platform/test/api_integration/services/index.ts index d492e52f6306..a934d40ebdea 100644 --- a/x-pack/platform/test/api_integration/services/index.ts +++ b/x-pack/platform/test/api_integration/services/index.ts @@ -16,12 +16,14 @@ import { FleetAndAgentsProvider } from './fleet_and_agents'; import { SpacesServiceProvider } from './spaces'; import { SearchSecureProvider } from './search_secure'; import { TransformProvider } from './transform'; +import { IndexManagementProvider } from './index_management'; export const services = { ...kibanaApiIntegrationServices, aiops: AiopsProvider, dataViewApi: DataViewApiProvider, esSupertestWithoutAuth: EsSupertestWithoutAuthProvider, + indexManagement: IndexManagementProvider, ingestPipelines: IngestPipelinesProvider, fleetAndAgents: FleetAndAgentsProvider, secureSearch: SearchSecureProvider, diff --git a/x-pack/test/api_integration/services/index_management.ts b/x-pack/platform/test/api_integration/services/index_management.ts similarity index 100% rename from x-pack/test/api_integration/services/index_management.ts rename to x-pack/platform/test/api_integration/services/index_management.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/config_basic.ts b/x-pack/platform/test/automatic_import_api_integration/apis/config_basic.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/config_basic.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/config_basic.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/config_graphs.ts b/x-pack/platform/test/automatic_import_api_integration/apis/config_graphs.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/config_graphs.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/config_graphs.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/analyze_api.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/analyze_api.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/analyze_api.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/analyze_api.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/analyze_logs.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/analyze_logs.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/analyze_logs.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/analyze_logs.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/categorization.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/categorization.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/categorization.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/categorization.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/cel.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/cel.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/cel.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/cel.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/ecs.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/ecs.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/ecs.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/ecs.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/related.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/related.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/basic/graphs/related.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/graphs/related.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/basic/index.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/index.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/basic/index.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/basic/index.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/graphs/analyze_api.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/analyze_api.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/graphs/analyze_api.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/analyze_api.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/graphs/categorization.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/categorization.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/graphs/categorization.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/categorization.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/graphs/cel.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/cel.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/graphs/cel.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/cel.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/graphs/ecs_mapping.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/ecs_mapping.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/graphs/ecs_mapping.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/ecs_mapping.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/graphs/index.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/index.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/graphs/index.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/index.ts diff --git a/x-pack/test/automatic_import_api_integration/apis/tests/graphs/related.ts b/x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/related.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/apis/tests/graphs/related.ts rename to x-pack/platform/test/automatic_import_api_integration/apis/tests/graphs/related.ts diff --git a/x-pack/test/automatic_import_api_integration/common/config.ts b/x-pack/platform/test/automatic_import_api_integration/common/config.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/config.ts rename to x-pack/platform/test/automatic_import_api_integration/common/config.ts diff --git a/x-pack/test/automatic_import_api_integration/common/ftr_provider_context.d.ts b/x-pack/platform/test/automatic_import_api_integration/common/ftr_provider_context.d.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/ftr_provider_context.d.ts rename to x-pack/platform/test/automatic_import_api_integration/common/ftr_provider_context.d.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/api/analyze_api.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/api/analyze_api.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/api/analyze_api.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/api/analyze_api.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/api/analyze_logs.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/api/analyze_logs.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/api/analyze_logs.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/api/analyze_logs.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/api/categorization.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/api/categorization.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/api/categorization.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/api/categorization.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/api/cel.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/api/cel.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/api/cel.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/api/cel.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/api/ecs.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/api/ecs.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/api/ecs.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/api/ecs.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/api/index.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/api/index.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/api/index.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/api/index.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/api/related.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/api/related.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/api/related.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/api/related.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/api/user_profiles.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/api/user_profiles.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/api/user_profiles.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/api/user_profiles.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/authentication/index.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/authentication/index.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/authentication/index.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/authentication/index.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/authentication/roles.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/authentication/roles.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/authentication/roles.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/authentication/roles.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/authentication/types.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/authentication/types.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/authentication/types.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/authentication/types.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/authentication/users.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/authentication/users.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/authentication/users.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/authentication/users.ts diff --git a/x-pack/test/automatic_import_api_integration/common/lib/error/error.ts b/x-pack/platform/test/automatic_import_api_integration/common/lib/error/error.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/lib/error/error.ts rename to x-pack/platform/test/automatic_import_api_integration/common/lib/error/error.ts diff --git a/x-pack/test/automatic_import_api_integration/common/services.ts b/x-pack/platform/test/automatic_import_api_integration/common/services.ts similarity index 100% rename from x-pack/test/automatic_import_api_integration/common/services.ts rename to x-pack/platform/test/automatic_import_api_integration/common/services.ts diff --git a/x-pack/platform/test/common/ftr_provider_context.ts b/x-pack/platform/test/common/ftr_provider_context.ts new file mode 100644 index 000000000000..5d731b9755a9 --- /dev/null +++ b/x-pack/platform/test/common/ftr_provider_context.ts @@ -0,0 +1,13 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { GenericFtrProviderContext, GenericFtrService } from '@kbn/test'; + +import { services } from '../api_integration/services'; + +export type FtrProviderContext = GenericFtrProviderContext; +export class FtrService extends GenericFtrService {} diff --git a/x-pack/platform/test/common/lib/test_data_loader.ts b/x-pack/platform/test/common/lib/test_data_loader.ts new file mode 100644 index 000000000000..20796fcd8e58 --- /dev/null +++ b/x-pack/platform/test/common/lib/test_data_loader.ts @@ -0,0 +1,200 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { LegacyUrlAlias } from '@kbn/core-saved-objects-base-server-internal'; +import { ALL_SAVED_OBJECT_INDICES } from '@kbn/core-saved-objects-server'; +import Fs from 'fs/promises'; +import { FtrProviderContext } from '../ftr_provider_context'; + +export const SPACE_1 = { + id: 'space_1', + name: 'Space 1', + description: 'This is the first test space', + disabledFeatures: [], +}; + +export const SPACE_2 = { + id: 'space_2', + name: 'Space 2', + description: 'This is the second test space', + disabledFeatures: [], +}; + +async function parseLegacyUrlAliases(path: string): Promise { + return (await Fs.readFile(path, 'utf-8')) + .split(/\r?\n\r?\n/) + .filter((line) => !!line) + .map((line) => JSON.parse(line)); +} + +// Objects can only be imported in one space at a time. To have test saved objects +// that are shared in multiple spaces we should import all objects in the "original" +// spaces first and then share them to other spaces as a subsequent operation. +const OBJECTS_TO_SHARE: Array<{ + spacesToAdd?: string[]; + spacesToRemove?: string[]; + objects: Array<{ type: string; id: string }>; +}> = [ + { + spacesToAdd: ['*'], + spacesToRemove: ['default'], + objects: [ + { type: 'sharedtype', id: 'all_spaces' }, + { type: 'sharedtype', id: 'space_2_only_matching_origin' }, + { type: 'sharedtype', id: 'alias_delete_exclusive' }, + ], + }, + { + spacesToRemove: ['default'], + spacesToAdd: [SPACE_1.id, SPACE_2.id], + objects: [{ type: 'sharedtype', id: 'space_1_and_space_2' }], + }, + { + spacesToAdd: [SPACE_1.id, SPACE_2.id], + objects: [ + { type: 'sharedtype', id: 'each_space' }, + { type: 'sharedtype', id: 'conflict_2_all' }, + { type: 'sharedtype', id: 'alias_delete_inclusive' }, + ], + }, + { + spacesToAdd: [SPACE_1.id], + objects: [ + { type: 'sharedtype', id: 'conflict_1c_default_and_space_1' }, + { type: 'sharedtype', id: 'default_and_space_1' }, + ], + }, + { + spacesToAdd: [SPACE_2.id], + objects: [{ type: 'sharedtype', id: 'default_and_space_2' }], + }, + { + spacesToAdd: [SPACE_1.id, SPACE_2.id], + objects: [{ type: 'resolvetype', id: 'conflict-newid' }], + }, +]; + +export function getTestDataLoader({ getService }: Pick) { + const spacesService = getService('spaces'); + const kbnServer = getService('kibanaServer'); + const supertest = getService('supertest'); + const log = getService('log'); + const es = getService('es'); + + return { + createFtrSpaces: async () => { + await Promise.all([await spacesService.create(SPACE_1), await spacesService.create(SPACE_2)]); + }, + + deleteFtrSpaces: async () => { + await Promise.all([spacesService.delete(SPACE_1.id), spacesService.delete(SPACE_2.id)]); + }, + + createFtrSavedObjectsData: async ( + spaceData: Array<{ spaceName: string | null; dataUrl: string }> + ) => { + log.debug('Loading test data for the following spaces: default, space_1 and space_2'); + + await Promise.all( + spaceData.map((spaceDataObj) => { + if (spaceDataObj.spaceName) { + return kbnServer.importExport.load(spaceDataObj.dataUrl, { + space: spaceDataObj.spaceName, + }); + } else { + return kbnServer.importExport.load(spaceDataObj.dataUrl); + } + }) + ); + + // Adjust spaces for the imported saved objects. + for (const { objects, spacesToAdd = [], spacesToRemove = [] } of OBJECTS_TO_SHARE) { + log.debug( + `Updating spaces for the following objects (add: [${spacesToAdd.join( + ', ' + )}], remove: [${spacesToRemove.join(', ')}]): ${objects + .map(({ type, id }) => `${type}:${id}`) + .join(', ')}` + ); + await supertest + .post('/api/spaces/_update_objects_spaces') + .send({ objects, spacesToAdd, spacesToRemove }) + .expect(200); + } + }, + + createLegacyUrlAliases: async ( + spaceData: Array<{ spaceName: string | null; dataUrl: string; disabled?: boolean }> + ) => { + await Promise.all( + spaceData.map(async (data) => { + const spaceString = data.spaceName ?? 'default'; + + const aliases = await parseLegacyUrlAliases(data.dataUrl); + log.info('creating', aliases.length, 'legacy URL aliases', { + space: spaceString, + }); + + await Promise.all( + aliases.map(async (alias) => { + await es.create({ + id: `legacy-url-alias:${spaceString}:${alias.targetType}:${alias.sourceId}`, + index: '.kibana', + refresh: 'wait_for', + document: { + type: 'legacy-url-alias', + updated_at: '2017-09-21T18:51:23.794Z', + 'legacy-url-alias': { + ...alias, + targetNamespace: spaceString, + ...(data.disabled && { disabled: data.disabled }), + }, + }, + }); + }) + ); + }) + ); + }, + + deleteFtrSavedObjectsData: async () => { + const allSpacesIds = [ + ...(await spacesService.getAll()).map((space: { id: string }) => space.id), + 'non_existent_space', + ]; + log.debug(`Removing data from the following spaces: ${allSpacesIds.join(', ')}`); + await Promise.all( + allSpacesIds.flatMap((spaceId) => [ + kbnServer.savedObjects.cleanStandardList({ space: spaceId }), + kbnServer.savedObjects.clean({ space: spaceId, types: ['sharedtype', 'isolatedtype'] }), + ]) + ); + }, + + deleteAllSavedObjectsFromKibanaIndex: async () => { + await es.deleteByQuery({ + index: ALL_SAVED_OBJECT_INDICES, + ignore_unavailable: true, + wait_for_completion: true, + conflicts: 'proceed', + query: { + bool: { + must_not: [ + { + term: { + type: { + value: 'space', + }, + }, + }, + ], + }, + }, + }); + }, + }; +} diff --git a/x-pack/test/monitoring_api_integration/README.md b/x-pack/platform/test/monitoring_api_integration/README.md similarity index 92% rename from x-pack/test/monitoring_api_integration/README.md rename to x-pack/platform/test/monitoring_api_integration/README.md index 9b05255fa72a..67e0947abe07 100644 --- a/x-pack/test/monitoring_api_integration/README.md +++ b/x-pack/platform/test/monitoring_api_integration/README.md @@ -12,7 +12,7 @@ the new versions of the packages. _Note that while Stack Monitoring currently supports 3 collection modes, the tests in this directory only focus on metricbeat and elastic-agent data. Tests for legacy -data are defined under `x-pack/test/api_integration/apis/monitoring`._ +data are defined under `x-pack/platform/test/api_integration/apis/monitoring`._ Since an elastic-agent integration spawns the corresponding metricbeat module under the hood (ie when an agent policy defines elasticsearch metrics data streams, @@ -43,15 +43,15 @@ test suite as CI step in the integrations package).** - Update the package version in `./packages.ts` - Create draft PR with the change to run against CI; or - Run the impacted test suite locally: - - start test server: `node scripts/functional_tests_server --config x-pack/test/monitoring_api_integration/config` - - start test suite for the updated component (eg Elasticsearch, Kibana..): `node scripts/functional_test_runner --config x-pack/test/monitoring_api_integration/config --grep ""` + - start test server: `node scripts/functional_tests_server --config x-pack/platform/test/monitoring_api_integration/config` + - start test suite for the updated component (eg Elasticsearch, Kibana..): `node scripts/functional_test_runner --config x-pack/platform/test/monitoring_api_integration/config --grep ""` ### Adding a new archive - Generate elastic-agent data for the relevant integration and archive the data with the kbn-es-archiver. Assuming the data is extracted from an elastic-package stack: `node scripts/es_archiver.js save 'metrics-.stack_monitoring.*' --es-url=https://elastic:changeme@localhost:9200 --es-ca=~/.elastic-package/profiles/default/certs/ca-cert.pem` - `` should point to a subdirectory of the `./archives` dir for consistency, - and since we're generating package data, end with `package` dir. example `/x-pack/test/monitoring_api_integration/archives/kibana/two-nodes/package` + and since we're generating package data, end with `package` dir. example `/x-pack/platform/test/monitoring_api_integration/archives/kibana/two-nodes/package` - `` should only contain a `data.json.gz`. make sure the `mappings.json` file was removed by the script - run the transform script to generate metricbeat data `node scripts/transform_archive --src /data.json.gz` - create a test case with the new archive diff --git a/x-pack/test/monitoring_api_integration/apis/apm/index.ts b/x-pack/platform/test/monitoring_api_integration/apis/apm/index.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/apis/apm/index.ts rename to x-pack/platform/test/monitoring_api_integration/apis/apm/index.ts diff --git a/x-pack/test/monitoring_api_integration/apis/apm/instances.ts b/x-pack/platform/test/monitoring_api_integration/apis/apm/instances.ts similarity index 95% rename from x-pack/test/monitoring_api_integration/apis/apm/instances.ts rename to x-pack/platform/test/monitoring_api_integration/apis/apm/instances.ts index 7c9571644db4..66b1d0199c23 100644 --- a/x-pack/test/monitoring_api_integration/apis/apm/instances.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/apm/instances.ts @@ -17,7 +17,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Instances', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/apm', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/apm', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/apm/overview.ts b/x-pack/platform/test/monitoring_api_integration/apis/apm/overview.ts similarity index 93% rename from x-pack/test/monitoring_api_integration/apis/apm/overview.ts rename to x-pack/platform/test/monitoring_api_integration/apis/apm/overview.ts index b97d515ecf4e..29b3d6a87b5c 100644 --- a/x-pack/test/monitoring_api_integration/apis/apm/overview.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/apm/overview.ts @@ -16,7 +16,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Overview', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/apm', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/apm', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/beats/beat.ts b/x-pack/platform/test/monitoring_api_integration/apis/beats/beat.ts similarity index 93% rename from x-pack/test/monitoring_api_integration/apis/beats/beat.ts rename to x-pack/platform/test/monitoring_api_integration/apis/beats/beat.ts index 8ed1ab8727f2..c225d670adf3 100644 --- a/x-pack/test/monitoring_api_integration/apis/beats/beat.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/beats/beat.ts @@ -17,7 +17,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Beat', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/beats', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/beats', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/beats/beats.ts b/x-pack/platform/test/monitoring_api_integration/apis/beats/beats.ts similarity index 92% rename from x-pack/test/monitoring_api_integration/apis/beats/beats.ts rename to x-pack/platform/test/monitoring_api_integration/apis/beats/beats.ts index 74158ed7e21d..d1bb11ac24b4 100644 --- a/x-pack/test/monitoring_api_integration/apis/beats/beats.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/beats/beats.ts @@ -17,7 +17,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Beats', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/beats', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/beats', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/beats/index.ts b/x-pack/platform/test/monitoring_api_integration/apis/beats/index.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/apis/beats/index.ts rename to x-pack/platform/test/monitoring_api_integration/apis/beats/index.ts diff --git a/x-pack/test/monitoring_api_integration/apis/beats/overview.ts b/x-pack/platform/test/monitoring_api_integration/apis/beats/overview.ts similarity index 94% rename from x-pack/test/monitoring_api_integration/apis/beats/overview.ts rename to x-pack/platform/test/monitoring_api_integration/apis/beats/overview.ts index 3c8b89a7a749..9cd14a48fc9a 100644 --- a/x-pack/test/monitoring_api_integration/apis/beats/overview.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/beats/overview.ts @@ -18,7 +18,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Overview', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/beats', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/beats', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/elasticsearch/ccr.ts b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/ccr.ts similarity index 94% rename from x-pack/test/monitoring_api_integration/apis/elasticsearch/ccr.ts rename to x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/ccr.ts index 5f3c4d1b7600..31c45cba06e6 100644 --- a/x-pack/test/monitoring_api_integration/apis/elasticsearch/ccr.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/ccr.ts @@ -18,7 +18,8 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'CCR', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node', + archiveRoot: + 'x-pack/platform/test/monitoring_api_integration/archives/elasticsearch/single_node', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/elasticsearch/index.ts b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/index.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/apis/elasticsearch/index.ts rename to x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/index.ts diff --git a/x-pack/test/monitoring_api_integration/apis/elasticsearch/indices.ts b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/indices.ts similarity index 96% rename from x-pack/test/monitoring_api_integration/apis/elasticsearch/indices.ts rename to x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/indices.ts index 85ed82ab7ee6..47efce3c29b1 100644 --- a/x-pack/test/monitoring_api_integration/apis/elasticsearch/indices.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/indices.ts @@ -20,7 +20,8 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Indices', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node', + archiveRoot: + 'x-pack/platform/test/monitoring_api_integration/archives/elasticsearch/single_node', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/elasticsearch/ml_jobs.ts b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/ml_jobs.ts similarity index 91% rename from x-pack/test/monitoring_api_integration/apis/elasticsearch/ml_jobs.ts rename to x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/ml_jobs.ts index 93d9c8a575bf..45e6581f88d7 100644 --- a/x-pack/test/monitoring_api_integration/apis/elasticsearch/ml_jobs.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/ml_jobs.ts @@ -17,7 +17,8 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'ML jobs', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node', + archiveRoot: + 'x-pack/platform/test/monitoring_api_integration/archives/elasticsearch/single_node', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/elasticsearch/nodes.ts b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/nodes.ts similarity index 95% rename from x-pack/test/monitoring_api_integration/apis/elasticsearch/nodes.ts rename to x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/nodes.ts index 44d02a043df5..19cf16b3a477 100644 --- a/x-pack/test/monitoring_api_integration/apis/elasticsearch/nodes.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/nodes.ts @@ -19,7 +19,8 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Nodes', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node', + archiveRoot: + 'x-pack/platform/test/monitoring_api_integration/archives/elasticsearch/single_node', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/elasticsearch/overview.ts b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/overview.ts similarity index 91% rename from x-pack/test/monitoring_api_integration/apis/elasticsearch/overview.ts rename to x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/overview.ts index 4632a67c9f9e..92d8b04dc8b1 100644 --- a/x-pack/test/monitoring_api_integration/apis/elasticsearch/overview.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/elasticsearch/overview.ts @@ -17,7 +17,8 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Overview', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node', + archiveRoot: + 'x-pack/platform/test/monitoring_api_integration/archives/elasticsearch/single_node', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/enterprisesearch/index.ts b/x-pack/platform/test/monitoring_api_integration/apis/enterprisesearch/index.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/apis/enterprisesearch/index.ts rename to x-pack/platform/test/monitoring_api_integration/apis/enterprisesearch/index.ts diff --git a/x-pack/test/monitoring_api_integration/apis/enterprisesearch/overview.ts b/x-pack/platform/test/monitoring_api_integration/apis/enterprisesearch/overview.ts similarity index 92% rename from x-pack/test/monitoring_api_integration/apis/enterprisesearch/overview.ts rename to x-pack/platform/test/monitoring_api_integration/apis/enterprisesearch/overview.ts index 3f5284af04ca..b20f471151da 100644 --- a/x-pack/test/monitoring_api_integration/apis/enterprisesearch/overview.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/enterprisesearch/overview.ts @@ -16,7 +16,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Overview', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/enterprisesearch', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/enterprisesearch', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/index.ts b/x-pack/platform/test/monitoring_api_integration/apis/index.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/apis/index.ts rename to x-pack/platform/test/monitoring_api_integration/apis/index.ts diff --git a/x-pack/test/monitoring_api_integration/apis/kibana/index.ts b/x-pack/platform/test/monitoring_api_integration/apis/kibana/index.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/apis/kibana/index.ts rename to x-pack/platform/test/monitoring_api_integration/apis/kibana/index.ts diff --git a/x-pack/test/monitoring_api_integration/apis/kibana/instances.ts b/x-pack/platform/test/monitoring_api_integration/apis/kibana/instances.ts similarity index 94% rename from x-pack/test/monitoring_api_integration/apis/kibana/instances.ts rename to x-pack/platform/test/monitoring_api_integration/apis/kibana/instances.ts index e530f18fb7a1..695bf95f59c5 100644 --- a/x-pack/test/monitoring_api_integration/apis/kibana/instances.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/kibana/instances.ts @@ -18,7 +18,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Instances', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/kibana/single_node', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/kibana/single_node', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/kibana/overview.ts b/x-pack/platform/test/monitoring_api_integration/apis/kibana/overview.ts similarity index 94% rename from x-pack/test/monitoring_api_integration/apis/kibana/overview.ts rename to x-pack/platform/test/monitoring_api_integration/apis/kibana/overview.ts index 3bb5bd3f3077..b8eee42ccca5 100644 --- a/x-pack/test/monitoring_api_integration/apis/kibana/overview.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/kibana/overview.ts @@ -18,7 +18,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Overview', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/kibana/single_node', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/kibana/single_node', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/logstash/index.ts b/x-pack/platform/test/monitoring_api_integration/apis/logstash/index.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/apis/logstash/index.ts rename to x-pack/platform/test/monitoring_api_integration/apis/logstash/index.ts diff --git a/x-pack/test/monitoring_api_integration/apis/logstash/nodes.ts b/x-pack/platform/test/monitoring_api_integration/apis/logstash/nodes.ts similarity index 95% rename from x-pack/test/monitoring_api_integration/apis/logstash/nodes.ts rename to x-pack/platform/test/monitoring_api_integration/apis/logstash/nodes.ts index b50ecd49ff09..3c25e4b5d851 100644 --- a/x-pack/test/monitoring_api_integration/apis/logstash/nodes.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/logstash/nodes.ts @@ -18,7 +18,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Nodes', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/logstash/single_node', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/logstash/single_node', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/logstash/overview.ts b/x-pack/platform/test/monitoring_api_integration/apis/logstash/overview.ts similarity index 91% rename from x-pack/test/monitoring_api_integration/apis/logstash/overview.ts rename to x-pack/platform/test/monitoring_api_integration/apis/logstash/overview.ts index b0272eb2ebab..310da8369a1c 100644 --- a/x-pack/test/monitoring_api_integration/apis/logstash/overview.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/logstash/overview.ts @@ -16,7 +16,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Overview', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/logstash/single_node', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/logstash/single_node', getService, }); diff --git a/x-pack/test/monitoring_api_integration/apis/logstash/pipelines.ts b/x-pack/platform/test/monitoring_api_integration/apis/logstash/pipelines.ts similarity index 97% rename from x-pack/test/monitoring_api_integration/apis/logstash/pipelines.ts rename to x-pack/platform/test/monitoring_api_integration/apis/logstash/pipelines.ts index cf3c2fcf2b35..8b702c0c939a 100644 --- a/x-pack/test/monitoring_api_integration/apis/logstash/pipelines.ts +++ b/x-pack/platform/test/monitoring_api_integration/apis/logstash/pipelines.ts @@ -18,7 +18,7 @@ export default function ({ getService }: FtrProviderContext) { const testRunner = getTestRunner({ testName: 'Pipelines', - archiveRoot: 'x-pack/test/monitoring_api_integration/archives/logstash/single_node', + archiveRoot: 'x-pack/platform/test/monitoring_api_integration/archives/logstash/single_node', getService, }); diff --git a/x-pack/test/monitoring_api_integration/archives/apm/metricbeat/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/apm/metricbeat/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/apm/metricbeat/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/apm/metricbeat/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/apm/package/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/apm/package/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/apm/package/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/apm/package/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/beats/metricbeat/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/beats/metricbeat/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/beats/metricbeat/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/beats/metricbeat/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/beats/package/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/beats/package/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/beats/package/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/beats/package/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node/metricbeat/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/elasticsearch/single_node/metricbeat/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node/metricbeat/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/elasticsearch/single_node/metricbeat/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node/package/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/elasticsearch/single_node/package/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node/package/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/elasticsearch/single_node/package/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/enterprisesearch/metricbeat/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/enterprisesearch/metricbeat/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/enterprisesearch/metricbeat/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/enterprisesearch/metricbeat/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/enterprisesearch/package/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/enterprisesearch/package/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/enterprisesearch/package/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/enterprisesearch/package/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/kibana/single_node/metricbeat/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/kibana/single_node/metricbeat/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/kibana/single_node/metricbeat/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/kibana/single_node/metricbeat/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/kibana/single_node/package/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/kibana/single_node/package/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/kibana/single_node/package/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/kibana/single_node/package/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/logstash/single_node/metricbeat/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/logstash/single_node/metricbeat/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/logstash/single_node/metricbeat/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/logstash/single_node/metricbeat/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/archives/logstash/single_node/package/data.json.gz b/x-pack/platform/test/monitoring_api_integration/archives/logstash/single_node/package/data.json.gz similarity index 100% rename from x-pack/test/monitoring_api_integration/archives/logstash/single_node/package/data.json.gz rename to x-pack/platform/test/monitoring_api_integration/archives/logstash/single_node/package/data.json.gz diff --git a/x-pack/test/monitoring_api_integration/config.ts b/x-pack/platform/test/monitoring_api_integration/config.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/config.ts rename to x-pack/platform/test/monitoring_api_integration/config.ts diff --git a/x-pack/test/monitoring_api_integration/fixtures/apm/instance.json b/x-pack/platform/test/monitoring_api_integration/fixtures/apm/instance.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/apm/instance.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/apm/instance.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/apm/instances.json b/x-pack/platform/test/monitoring_api_integration/fixtures/apm/instances.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/apm/instances.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/apm/instances.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/apm/overview.json b/x-pack/platform/test/monitoring_api_integration/fixtures/apm/overview.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/apm/overview.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/apm/overview.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/beats/beat.json b/x-pack/platform/test/monitoring_api_integration/fixtures/beats/beat.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/beats/beat.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/beats/beat.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/beats/beats.json b/x-pack/platform/test/monitoring_api_integration/fixtures/beats/beats.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/beats/beats.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/beats/beats.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/beats/overview.json b/x-pack/platform/test/monitoring_api_integration/fixtures/beats/overview.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/beats/overview.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/beats/overview.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/ccr.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/ccr.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/ccr.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/ccr.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/ccr_shard.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/ccr_shard.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/ccr_shard.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/ccr_shard.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/index_detail.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/index_detail.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/index_detail.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/index_detail.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/index_detail_advanced.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/index_detail_advanced.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/index_detail_advanced.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/index_detail_advanced.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/indices_all.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/indices_all.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/indices_all.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/indices_all.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/indices_no_system.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/indices_no_system.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/indices_no_system.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/indices_no_system.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/ml_jobs.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/ml_jobs.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/ml_jobs.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/ml_jobs.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/node_detail.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/node_detail.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/node_detail.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/node_detail.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/node_detail_advanced.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/node_detail_advanced.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/node_detail_advanced.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/node_detail_advanced.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/nodes.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/nodes.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/nodes.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/nodes.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/elasticsearch/overview.json b/x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/overview.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/elasticsearch/overview.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/elasticsearch/overview.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/enterprisesearch/overview.json b/x-pack/platform/test/monitoring_api_integration/fixtures/enterprisesearch/overview.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/enterprisesearch/overview.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/enterprisesearch/overview.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/kibana/cluster_overview.json b/x-pack/platform/test/monitoring_api_integration/fixtures/kibana/cluster_overview.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/kibana/cluster_overview.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/kibana/cluster_overview.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/kibana/instance.json b/x-pack/platform/test/monitoring_api_integration/fixtures/kibana/instance.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/kibana/instance.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/kibana/instance.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/kibana/instances.json b/x-pack/platform/test/monitoring_api_integration/fixtures/kibana/instances.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/kibana/instances.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/kibana/instances.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/kibana/kibana_overview.json b/x-pack/platform/test/monitoring_api_integration/fixtures/kibana/kibana_overview.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/kibana/kibana_overview.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/kibana/kibana_overview.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/logstash/node_detail.json b/x-pack/platform/test/monitoring_api_integration/fixtures/logstash/node_detail.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/logstash/node_detail.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/logstash/node_detail.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/logstash/node_detail_advanced.json b/x-pack/platform/test/monitoring_api_integration/fixtures/logstash/node_detail_advanced.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/logstash/node_detail_advanced.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/logstash/node_detail_advanced.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/logstash/nodes.json b/x-pack/platform/test/monitoring_api_integration/fixtures/logstash/nodes.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/logstash/nodes.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/logstash/nodes.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/logstash/overview.json b/x-pack/platform/test/monitoring_api_integration/fixtures/logstash/overview.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/logstash/overview.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/logstash/overview.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/logstash/pipeline.json b/x-pack/platform/test/monitoring_api_integration/fixtures/logstash/pipeline.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/logstash/pipeline.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/logstash/pipeline.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/logstash/pipelines.json b/x-pack/platform/test/monitoring_api_integration/fixtures/logstash/pipelines.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/logstash/pipelines.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/logstash/pipelines.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/logstash/vertex.json b/x-pack/platform/test/monitoring_api_integration/fixtures/logstash/vertex.json similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/logstash/vertex.json rename to x-pack/platform/test/monitoring_api_integration/fixtures/logstash/vertex.json diff --git a/x-pack/test/monitoring_api_integration/fixtures/packages/beat-0.1.3.zip b/x-pack/platform/test/monitoring_api_integration/fixtures/packages/beat-0.1.3.zip similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/packages/beat-0.1.3.zip rename to x-pack/platform/test/monitoring_api_integration/fixtures/packages/beat-0.1.3.zip diff --git a/x-pack/test/monitoring_api_integration/fixtures/packages/elasticsearch-1.4.1.zip b/x-pack/platform/test/monitoring_api_integration/fixtures/packages/elasticsearch-1.4.1.zip similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/packages/elasticsearch-1.4.1.zip rename to x-pack/platform/test/monitoring_api_integration/fixtures/packages/elasticsearch-1.4.1.zip diff --git a/x-pack/test/monitoring_api_integration/fixtures/packages/enterprisesearch-1.0.0.zip b/x-pack/platform/test/monitoring_api_integration/fixtures/packages/enterprisesearch-1.0.0.zip similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/packages/enterprisesearch-1.0.0.zip rename to x-pack/platform/test/monitoring_api_integration/fixtures/packages/enterprisesearch-1.0.0.zip diff --git a/x-pack/test/monitoring_api_integration/fixtures/packages/kibana-2.3.0-preview1.zip b/x-pack/platform/test/monitoring_api_integration/fixtures/packages/kibana-2.3.0-preview1.zip similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/packages/kibana-2.3.0-preview1.zip rename to x-pack/platform/test/monitoring_api_integration/fixtures/packages/kibana-2.3.0-preview1.zip diff --git a/x-pack/test/monitoring_api_integration/fixtures/packages/logstash-2.2.2-preview1.zip b/x-pack/platform/test/monitoring_api_integration/fixtures/packages/logstash-2.2.2-preview1.zip similarity index 100% rename from x-pack/test/monitoring_api_integration/fixtures/packages/logstash-2.2.2-preview1.zip rename to x-pack/platform/test/monitoring_api_integration/fixtures/packages/logstash-2.2.2-preview1.zip diff --git a/x-pack/test/monitoring_api_integration/packages.ts b/x-pack/platform/test/monitoring_api_integration/packages.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/packages.ts rename to x-pack/platform/test/monitoring_api_integration/packages.ts diff --git a/x-pack/test/monitoring_api_integration/scripts/transform_archive.js b/x-pack/platform/test/monitoring_api_integration/scripts/transform_archive.js similarity index 93% rename from x-pack/test/monitoring_api_integration/scripts/transform_archive.js rename to x-pack/platform/test/monitoring_api_integration/scripts/transform_archive.js index 06b08dee7426..f07d5c498bbd 100644 --- a/x-pack/test/monitoring_api_integration/scripts/transform_archive.js +++ b/x-pack/platform/test/monitoring_api_integration/scripts/transform_archive.js @@ -5,7 +5,7 @@ * 2.0. */ -require('../../../../src/setup_node_env'); +require('../../../../../src/setup_node_env'); const { createReadStream, createWriteStream } = require('fs'); const { mkdir, rm } = require('fs/promises'); @@ -16,7 +16,7 @@ const { createPromiseFromStreams } = require('@kbn/utils'); const { createParseArchiveStreams, -} = require('../../../../src/platform/packages/shared/kbn-es-archiver/src/lib/archives/parse'); // eslint-disable-line @kbn/imports/uniform_imports +} = require('../../../../../src/platform/packages/shared/kbn-es-archiver/src/lib/archives/parse'); // eslint-disable-line @kbn/imports/uniform_imports /** * generates .monitoring-* (metricbeat) archive from a metrics-* (package) archive diff --git a/x-pack/test/monitoring_api_integration/utils/lifecycle_methods.ts b/x-pack/platform/test/monitoring_api_integration/utils/lifecycle_methods.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/utils/lifecycle_methods.ts rename to x-pack/platform/test/monitoring_api_integration/utils/lifecycle_methods.ts diff --git a/x-pack/test/monitoring_api_integration/utils/test_runner.ts b/x-pack/platform/test/monitoring_api_integration/utils/test_runner.ts similarity index 100% rename from x-pack/test/monitoring_api_integration/utils/test_runner.ts rename to x-pack/platform/test/monitoring_api_integration/utils/test_runner.ts diff --git a/x-pack/test/saved_object_api_integration/common/config.ts b/x-pack/platform/test/saved_object_api_integration/common/config.ts similarity index 92% rename from x-pack/test/saved_object_api_integration/common/config.ts rename to x-pack/platform/test/saved_object_api_integration/common/config.ts index 363c48e0bf76..9689b1c168ac 100644 --- a/x-pack/test/saved_object_api_integration/common/config.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/config.ts @@ -6,7 +6,6 @@ */ import path from 'path'; -import { REPO_ROOT } from '@kbn/repo-info'; import { FtrConfigProviderContext } from '@kbn/test'; import { ScoutTestRunConfigCategory } from '@kbn/scout-info'; @@ -23,9 +22,7 @@ export function createTestConfig(name: string, options: CreateTestConfigOptions) return async ({ readConfigFile }: FtrConfigProviderContext) => { const config = { kibana: { - api: await readConfigFile( - path.resolve(REPO_ROOT, 'src/platform/test/api_integration/config.js') - ), + api: await readConfigFile(require.resolve('@kbn/test-suites-src/api_integration/config')), functional: await readConfigFile( require.resolve('@kbn/test-suites-src/functional/config.base') ), diff --git a/x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces/data.json b/x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces/data.json similarity index 100% rename from x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces/data.json rename to x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces/data.json diff --git a/x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/default_space.json b/x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/default_space.json similarity index 100% rename from x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/default_space.json rename to x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/default_space.json diff --git a/x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json b/x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json similarity index 100% rename from x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json rename to x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json diff --git a/x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_1.json b/x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_1.json similarity index 100% rename from x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_1.json rename to x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_1.json diff --git a/x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_2.json b/x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_2.json similarity index 100% rename from x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_2.json rename to x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_2.json diff --git a/x-pack/test/saved_object_api_integration/common/ftr_provider_context.d.ts b/x-pack/platform/test/saved_object_api_integration/common/ftr_provider_context.d.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/common/ftr_provider_context.d.ts rename to x-pack/platform/test/saved_object_api_integration/common/ftr_provider_context.d.ts diff --git a/x-pack/test/saved_object_api_integration/common/lib/authentication.ts b/x-pack/platform/test/saved_object_api_integration/common/lib/authentication.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/common/lib/authentication.ts rename to x-pack/platform/test/saved_object_api_integration/common/lib/authentication.ts diff --git a/x-pack/test/saved_object_api_integration/common/lib/create_users_and_roles.ts b/x-pack/platform/test/saved_object_api_integration/common/lib/create_users_and_roles.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/common/lib/create_users_and_roles.ts rename to x-pack/platform/test/saved_object_api_integration/common/lib/create_users_and_roles.ts diff --git a/x-pack/test/saved_object_api_integration/common/lib/saved_object_test_cases.ts b/x-pack/platform/test/saved_object_api_integration/common/lib/saved_object_test_cases.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/common/lib/saved_object_test_cases.ts rename to x-pack/platform/test/saved_object_api_integration/common/lib/saved_object_test_cases.ts diff --git a/x-pack/test/saved_object_api_integration/common/lib/saved_object_test_utils.ts b/x-pack/platform/test/saved_object_api_integration/common/lib/saved_object_test_utils.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/common/lib/saved_object_test_utils.ts rename to x-pack/platform/test/saved_object_api_integration/common/lib/saved_object_test_utils.ts diff --git a/x-pack/test/saved_object_api_integration/common/lib/spaces.ts b/x-pack/platform/test/saved_object_api_integration/common/lib/spaces.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/common/lib/spaces.ts rename to x-pack/platform/test/saved_object_api_integration/common/lib/spaces.ts diff --git a/x-pack/test/saved_object_api_integration/common/lib/types.ts b/x-pack/platform/test/saved_object_api_integration/common/lib/types.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/common/lib/types.ts rename to x-pack/platform/test/saved_object_api_integration/common/lib/types.ts diff --git a/x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/kibana.jsonc b/x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/kibana.jsonc similarity index 79% rename from x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/kibana.jsonc rename to x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/kibana.jsonc index 8caa71f61578..82ac51905e9c 100644 --- a/x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/kibana.jsonc +++ b/x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/kibana.jsonc @@ -2,6 +2,8 @@ "type": "plugin", "id": "@kbn/saved-object-test-plugin", "owner": "@elastic/kibana-security", + "group": "platform", + "visibility": "private", "plugin": { "id": "savedObjectTestPlugin", "server": true, diff --git a/x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/server/index.ts b/x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/server/index.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/server/index.ts rename to x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/server/index.ts diff --git a/x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/server/plugin.ts b/x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/server/plugin.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/server/plugin.ts rename to x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/server/plugin.ts diff --git a/x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/tsconfig.json b/x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/tsconfig.json similarity index 81% rename from x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/tsconfig.json rename to x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/tsconfig.json index 201ae6ddf08e..34d55f55ded6 100644 --- a/x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/tsconfig.json +++ b/x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin/tsconfig.json @@ -1,5 +1,5 @@ { - "extends": "../../../../../../tsconfig.base.json", + "extends": "../../../../../../../tsconfig.base.json", "compilerOptions": { "outDir": "target/types", "isolatedModules": true diff --git a/x-pack/test/saved_object_api_integration/common/services/index.ts b/x-pack/platform/test/saved_object_api_integration/common/services/index.ts similarity index 69% rename from x-pack/test/saved_object_api_integration/common/services/index.ts rename to x-pack/platform/test/saved_object_api_integration/common/services/index.ts index 98129d9cc5da..871070b38996 100644 --- a/x-pack/test/saved_object_api_integration/common/services/index.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/services/index.ts @@ -5,10 +5,8 @@ * 2.0. */ -import { services as commonServices } from '../../../common/services'; import { services as apiIntegrationServices } from '../../../api_integration/services'; export const services = { - ...commonServices, - esSupertestWithoutAuth: apiIntegrationServices.esSupertestWithoutAuth, + ...apiIntegrationServices, }; diff --git a/x-pack/test/saved_object_api_integration/common/suites/bulk_create.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/bulk_create.ts similarity index 92% rename from x-pack/test/saved_object_api_integration/common/suites/bulk_create.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/bulk_create.ts index 6b79b3448911..8f925680b903 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/bulk_create.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/bulk_create.ts @@ -207,39 +207,39 @@ export function bulkCreateTestSuiteFactory(context: FtrProviderContext) { { spaceName: null, dataUrl: - 'x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/default_space.json', + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/default_space.json', }, { spaceName: SPACE_1.id, dataUrl: - 'x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_1.json', + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_1.json', }, { spaceName: SPACE_2.id, dataUrl: - 'x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_2.json', + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_2.json', }, ]); await testDataLoader.createLegacyUrlAliases([ { spaceName: null, dataUrl: - 'x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json', + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json', }, { spaceName: SPACE_1.id, dataUrl: - 'x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json', + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json', }, { spaceName: 'space_x', dataUrl: - 'x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json', + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json', }, { spaceName: 'space_y', dataUrl: - 'x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json', + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/legacy_url_aliases.json', disabled: true, }, ]); diff --git a/x-pack/test/saved_object_api_integration/common/suites/bulk_delete.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/bulk_delete.ts similarity index 96% rename from x-pack/test/saved_object_api_integration/common/suites/bulk_delete.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/bulk_delete.ts index 4df8b9cd5021..16bec007bd69 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/bulk_delete.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/bulk_delete.ts @@ -120,12 +120,12 @@ export function bulkDeleteTestSuiteFactory(context: FtrProviderContext) { describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/bulk_get.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/bulk_get.ts similarity index 94% rename from x-pack/test/saved_object_api_integration/common/suites/bulk_get.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/bulk_get.ts index d25d1e0a5d87..bf76f4c278e5 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/bulk_get.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/bulk_get.ts @@ -101,17 +101,17 @@ export function bulkGetTestSuiteFactory(context: FtrProviderContext) { { spaceName: null, dataUrl: - 'x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/default_space.json', + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/default_space.json', }, { spaceName: SPACE_1.id, dataUrl: - 'x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_1.json', + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_1.json', }, { spaceName: SPACE_2.id, dataUrl: - 'x-pack/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_2.json', + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/kbn_archiver/space_2.json', }, ]); }); diff --git a/x-pack/test/saved_object_api_integration/common/suites/bulk_resolve.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/bulk_resolve.ts similarity index 95% rename from x-pack/test/saved_object_api_integration/common/suites/bulk_resolve.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/bulk_resolve.ts index b3c8669d4821..572e2570e329 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/bulk_resolve.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/bulk_resolve.ts @@ -106,12 +106,12 @@ export function bulkResolveTestSuiteFactory(esArchiver: any, supertest: SuperTes describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/bulk_update.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/bulk_update.ts similarity index 95% rename from x-pack/test/saved_object_api_integration/common/suites/bulk_update.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/bulk_update.ts index 384b8db8aa0a..48d76ad72fa1 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/bulk_update.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/bulk_update.ts @@ -102,12 +102,12 @@ export function bulkUpdateTestSuiteFactory(esArchiver: any, supertest: SuperTest describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/create.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/create.ts similarity index 96% rename from x-pack/test/saved_object_api_integration/common/suites/create.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/create.ts index b12fef1c7cad..9aacc2d73e26 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/create.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/create.ts @@ -135,12 +135,12 @@ export function createTestSuiteFactory(esArchiver: any, supertest: SuperTestAgen describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/delete.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/delete.ts similarity index 95% rename from x-pack/test/saved_object_api_integration/common/suites/delete.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/delete.ts index c24a816d06bc..e8289257d257 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/delete.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/delete.ts @@ -101,12 +101,12 @@ export function deleteTestSuiteFactory(es: Client, esArchiver: any, supertest: S describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/export.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/export.ts similarity index 97% rename from x-pack/test/saved_object_api_integration/common/suites/export.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/export.ts index b7936f94a98f..acad9cf1f7ed 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/export.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/export.ts @@ -246,12 +246,12 @@ export function exportTestSuiteFactory(esArchiver: any, supertest: SuperTestAgen describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/find.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/find.ts similarity index 98% rename from x-pack/test/saved_object_api_integration/common/suites/find.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/find.ts index c7afc205f5b6..93e1529b64c3 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/find.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/find.ts @@ -283,12 +283,12 @@ export function findTestSuiteFactory(esArchiver: any, supertest: SuperTestAgent) describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/get.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/get.ts similarity index 93% rename from x-pack/test/saved_object_api_integration/common/suites/get.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/get.ts index 024f061d2cb2..0d18238541fc 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/get.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/get.ts @@ -67,12 +67,12 @@ export function getTestSuiteFactory(esArchiver: any, supertest: SuperTestAgent) describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/import.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/import.ts similarity index 98% rename from x-pack/test/saved_object_api_integration/common/suites/import.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/import.ts index 1af1bf07510b..d04a4c2fda2a 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/import.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/import.ts @@ -287,12 +287,12 @@ export function importTestSuiteFactory(es: Client, esArchiver: any, supertest: S describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/resolve.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/resolve.ts similarity index 95% rename from x-pack/test/saved_object_api_integration/common/suites/resolve.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/resolve.ts index 8f03686d4cab..e174eca9783a 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/resolve.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/resolve.ts @@ -121,12 +121,12 @@ export function resolveTestSuiteFactory(esArchiver: any, supertest: SuperTestAge describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/resolve_import_errors.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/resolve_import_errors.ts similarity index 98% rename from x-pack/test/saved_object_api_integration/common/suites/resolve_import_errors.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/resolve_import_errors.ts index 09ff10344911..eaff6ffc90ec 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/resolve_import_errors.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/resolve_import_errors.ts @@ -354,12 +354,12 @@ export function resolveImportErrorsTestSuiteFactory( describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/common/suites/update.ts b/x-pack/platform/test/saved_object_api_integration/common/suites/update.ts similarity index 94% rename from x-pack/test/saved_object_api_integration/common/suites/update.ts rename to x-pack/platform/test/saved_object_api_integration/common/suites/update.ts index ee37e0feccfe..1fa671a37b1f 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/update.ts +++ b/x-pack/platform/test/saved_object_api_integration/common/suites/update.ts @@ -78,12 +78,12 @@ export function updateTestSuiteFactory(esArchiver: any, supertest: SuperTestAgen describeFn(description, () => { before(() => esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); after(() => esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ) ); diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_create.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/bulk_create.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_create.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/bulk_create.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_delete.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/bulk_delete.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_delete.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/bulk_delete.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_get.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/bulk_get.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_get.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/bulk_get.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_resolve.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/bulk_resolve.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_resolve.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/bulk_resolve.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_update.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/bulk_update.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_update.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/bulk_update.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/create.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/create.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/create.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/create.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/delete.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/delete.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/delete.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/delete.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/export.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/export.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/export.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/export.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/find.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/find.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/find.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/find.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/get.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/get.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/get.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/get.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/import.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/import.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/import.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/import.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/index.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/index.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/index.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/index.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/resolve.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/resolve.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/resolve.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/resolve.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/resolve_import_errors.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/resolve_import_errors.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/resolve_import_errors.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/resolve_import_errors.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/apis/update.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/update.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/apis/update.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/apis/update.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/config_basic.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/config_basic.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/config_basic.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/config_basic.ts diff --git a/x-pack/test/saved_object_api_integration/security_and_spaces/config_trial.ts b/x-pack/platform/test/saved_object_api_integration/security_and_spaces/config_trial.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/security_and_spaces/config_trial.ts rename to x-pack/platform/test/saved_object_api_integration/security_and_spaces/config_trial.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_create.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/bulk_create.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_create.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/bulk_create.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_delete.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/bulk_delete.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_delete.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/bulk_delete.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_get.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/bulk_get.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_get.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/bulk_get.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_resolve.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/bulk_resolve.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_resolve.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/bulk_resolve.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_update.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/bulk_update.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_update.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/bulk_update.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/create.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/create.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/create.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/create.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/delete.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/delete.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/delete.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/delete.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/export.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/export.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/export.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/export.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/find.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/find.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/find.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/find.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/get.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/get.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/get.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/get.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/import.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/import.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/import.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/import.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/index.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/index.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/index.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/index.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/resolve.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/resolve.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/resolve.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/resolve.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/resolve_import_errors.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/resolve_import_errors.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/resolve_import_errors.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/resolve_import_errors.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/update.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/apis/update.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/apis/update.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/apis/update.ts diff --git a/x-pack/test/saved_object_api_integration/spaces_only/config.ts b/x-pack/platform/test/saved_object_api_integration/spaces_only/config.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/spaces_only/config.ts rename to x-pack/platform/test/saved_object_api_integration/spaces_only/config.ts diff --git a/x-pack/test/saved_object_api_integration/user_profiles/apis/bulk_create.ts b/x-pack/platform/test/saved_object_api_integration/user_profiles/apis/bulk_create.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/user_profiles/apis/bulk_create.ts rename to x-pack/platform/test/saved_object_api_integration/user_profiles/apis/bulk_create.ts diff --git a/x-pack/test/saved_object_api_integration/user_profiles/apis/bulk_update.ts b/x-pack/platform/test/saved_object_api_integration/user_profiles/apis/bulk_update.ts similarity index 94% rename from x-pack/test/saved_object_api_integration/user_profiles/apis/bulk_update.ts rename to x-pack/platform/test/saved_object_api_integration/user_profiles/apis/bulk_update.ts index f7b5098d921d..f3e8c6472d02 100644 --- a/x-pack/test/saved_object_api_integration/user_profiles/apis/bulk_update.ts +++ b/x-pack/platform/test/saved_object_api_integration/user_profiles/apis/bulk_update.ts @@ -17,13 +17,13 @@ export default function ({ getService }: FtrProviderContext) { describe('bulk_update', function () { before(async () => { await esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ); }); after(async () => { await esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ); }); diff --git a/x-pack/test/saved_object_api_integration/user_profiles/apis/create.ts b/x-pack/platform/test/saved_object_api_integration/user_profiles/apis/create.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/user_profiles/apis/create.ts rename to x-pack/platform/test/saved_object_api_integration/user_profiles/apis/create.ts diff --git a/x-pack/test/saved_object_api_integration/user_profiles/apis/index.ts b/x-pack/platform/test/saved_object_api_integration/user_profiles/apis/index.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/user_profiles/apis/index.ts rename to x-pack/platform/test/saved_object_api_integration/user_profiles/apis/index.ts diff --git a/x-pack/test/saved_object_api_integration/user_profiles/apis/update.ts b/x-pack/platform/test/saved_object_api_integration/user_profiles/apis/update.ts similarity index 96% rename from x-pack/test/saved_object_api_integration/user_profiles/apis/update.ts rename to x-pack/platform/test/saved_object_api_integration/user_profiles/apis/update.ts index 48f388003c4a..4ac5945b5062 100644 --- a/x-pack/test/saved_object_api_integration/user_profiles/apis/update.ts +++ b/x-pack/platform/test/saved_object_api_integration/user_profiles/apis/update.ts @@ -17,13 +17,13 @@ export default function ({ getService }: FtrProviderContext) { describe('update', function () { before(async () => { await esArchiver.load( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ); }); after(async () => { await esArchiver.unload( - 'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' + 'x-pack/platform/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces' ); }); diff --git a/x-pack/test/saved_object_api_integration/user_profiles/config.ts b/x-pack/platform/test/saved_object_api_integration/user_profiles/config.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/user_profiles/config.ts rename to x-pack/platform/test/saved_object_api_integration/user_profiles/config.ts diff --git a/x-pack/test/saved_object_api_integration/user_profiles/helpers.ts b/x-pack/platform/test/saved_object_api_integration/user_profiles/helpers.ts similarity index 100% rename from x-pack/test/saved_object_api_integration/user_profiles/helpers.ts rename to x-pack/platform/test/saved_object_api_integration/user_profiles/helpers.ts diff --git a/x-pack/platform/test/tsconfig.json b/x-pack/platform/test/tsconfig.json index cf732a969d9c..93cf8117669a 100644 --- a/x-pack/platform/test/tsconfig.json +++ b/x-pack/platform/test/tsconfig.json @@ -9,7 +9,11 @@ "@kbn/ambient-ui-types", "@kbn/ambient-ftr-types" ], - "resolveJsonModule": true, + // there is still a decent amount of JS in this plugin and we are taking + // advantage of the fact that TS doesn't know the types of that code and + // gives us `any`. Once that code is converted to .ts we can remove this + // and allow TS to infer types from any JS file imported. + "allowJs": false }, "include": [ "**/*", @@ -19,8 +23,14 @@ "./api_integration/apis/logstash/pipeline/fixtures/*.json", "./api_integration/apis/logstash/pipelines/fixtures/*.json", "./api_integration/apis/telemetry/fixtures/*.json", + "./monitoring_api_integration/fixtures/**/*.json", + ], + "exclude": [ + "target/**/*", + "*/plugins/**/*", + "*/packages/**/*", + "*/*/packages/**/*" ], - "exclude": ["target/**/*", "*/plugins/**/*", "plugins/**/*"], "kbn_references": [ "@kbn/test-suites-src", "@kbn/telemetry-collection-manager-plugin", @@ -52,5 +62,15 @@ "@kbn/aiops-log-rate-analysis", "@kbn/aiops-test-utils", "@kbn/ml-agg-utils", + "@kbn/share-plugin", + "@kbn/tooling-log", + "@kbn/cross-cluster-replication-plugin", + "@kbn/index-management-plugin", + "@kbn/snapshot-restore-plugin", + "@kbn/monitoring-plugin", + "@kbn/automatic-import-plugin", + "@kbn/core-saved-objects-base-server-internal", + "@kbn/utils", + "@kbn/core", ] } diff --git a/x-pack/test/api_integration/services/index.ts b/x-pack/test/api_integration/services/index.ts index f6561446cc75..7552f1464e1d 100644 --- a/x-pack/test/api_integration/services/index.ts +++ b/x-pack/test/api_integration/services/index.ts @@ -19,7 +19,6 @@ import { MachineLearningProvider } from './ml'; import { IngestManagerProvider } from '../../common/services/ingest_manager'; import { TransformProvider } from './transform'; import { IngestPipelinesProvider } from './ingest_pipelines'; -import { IndexManagementProvider } from './index_management'; import { DataViewApiProvider } from './data_view_api'; import { SloApiProvider } from './slo'; import { SecuritySolutionApiProvider } from './security_solution_api.gen'; @@ -40,7 +39,6 @@ export const services = { ingestManager: IngestManagerProvider, transform: TransformProvider, ingestPipelines: IngestPipelinesProvider, - indexManagement: IndexManagementProvider, slo: SloApiProvider, securitySolutionApi: SecuritySolutionApiProvider, fleetAndAgents: FleetAndAgents, diff --git a/x-pack/test/fleet_api_integration/apis/epm/template.ts b/x-pack/test/fleet_api_integration/apis/epm/template.ts index fb6fa9c601fc..55255172013b 100644 --- a/x-pack/test/fleet_api_integration/apis/epm/template.ts +++ b/x-pack/test/fleet_api_integration/apis/epm/template.ts @@ -15,7 +15,7 @@ export default function ({ getService }: FtrProviderContext) { const templateIndexPattern = 'bar-*'; const es = getService('es'); - // This test was inspired by https://github.com/elastic/kibana/blob/main/x-pack/test/api_integration/apis/monitoring/common/mappings_exist.js + // This test was inspired by https://github.com/elastic/kibana/blob/main/x-pack/platform/test/api_integration/apis/monitoring/common/mappings_exist.js describe('EPM - template', () => { beforeEach(async () => { appContextService.start({ diff --git a/x-pack/test/spaces_api_integration/common/suites/disable_legacy_url_aliases.ts b/x-pack/test/spaces_api_integration/common/suites/disable_legacy_url_aliases.ts index 10cb486ac263..02f20cc0a8b8 100644 --- a/x-pack/test/spaces_api_integration/common/suites/disable_legacy_url_aliases.ts +++ b/x-pack/test/spaces_api_integration/common/suites/disable_legacy_url_aliases.ts @@ -11,13 +11,13 @@ import type { Agent as SuperTestAgent } from 'supertest'; import type { LegacyUrlAlias } from '@kbn/core-saved-objects-base-server-internal'; import { MAIN_SAVED_OBJECT_INDEX } from '@kbn/core-saved-objects-server'; import expect from '@kbn/expect'; - -import { getUrlPrefix } from '../../../saved_object_api_integration/common/lib/saved_object_test_utils'; +import { getUrlPrefix } from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/saved_object_test_utils'; import type { ExpectResponseBody, TestDefinition, TestSuite, -} from '../../../saved_object_api_integration/common/lib/types'; +} from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/types'; + import { SPACES } from '../lib/spaces'; export interface DisableLegacyUrlAliasesTestDefinition extends TestDefinition { diff --git a/x-pack/test/spaces_api_integration/common/suites/get_shareable_references.ts b/x-pack/test/spaces_api_integration/common/suites/get_shareable_references.ts index a384abab72dc..508b74e842b2 100644 --- a/x-pack/test/spaces_api_integration/common/suites/get_shareable_references.ts +++ b/x-pack/test/spaces_api_integration/common/suites/get_shareable_references.ts @@ -13,16 +13,16 @@ import type { } from '@kbn/core/server'; import expect from '@kbn/expect'; import { deepFreeze } from '@kbn/std'; - import { expectResponses, getUrlPrefix, -} from '../../../saved_object_api_integration/common/lib/saved_object_test_utils'; +} from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/saved_object_test_utils'; import type { ExpectResponseBody, TestDefinition, TestSuite, -} from '../../../saved_object_api_integration/common/lib/types'; +} from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/types'; + import { MULTI_NAMESPACE_SAVED_OBJECT_TEST_CASES as CASES } from '../lib/saved_object_test_cases'; import { SPACES } from '../lib/spaces'; diff --git a/x-pack/test/spaces_api_integration/common/suites/update_objects_spaces.ts b/x-pack/test/spaces_api_integration/common/suites/update_objects_spaces.ts index de5c716b35ac..6b4483b056b6 100644 --- a/x-pack/test/spaces_api_integration/common/suites/update_objects_spaces.ts +++ b/x-pack/test/spaces_api_integration/common/suites/update_objects_spaces.ts @@ -14,16 +14,16 @@ import type { SavedObjectsUpdateObjectsSpacesResponse } from '@kbn/core/server'; import { SavedObjectsErrorHelpers } from '@kbn/core/server'; import { ALL_SAVED_OBJECT_INDICES } from '@kbn/core-saved-objects-server'; import expect from '@kbn/expect'; - import { expectResponses, getUrlPrefix, -} from '../../../saved_object_api_integration/common/lib/saved_object_test_utils'; +} from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/saved_object_test_utils'; import type { ExpectResponseBody, TestDefinition, TestSuite, -} from '../../../saved_object_api_integration/common/lib/types'; +} from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/types'; + import { SPACES } from '../lib/spaces'; export interface UpdateObjectsSpacesTestDefinition extends TestDefinition { diff --git a/x-pack/test/spaces_api_integration/security_and_spaces/apis/disable_legacy_url_aliases.ts b/x-pack/test/spaces_api_integration/security_and_spaces/apis/disable_legacy_url_aliases.ts index 2498ce166bcc..86a5bca94f13 100644 --- a/x-pack/test/spaces_api_integration/security_and_spaces/apis/disable_legacy_url_aliases.ts +++ b/x-pack/test/spaces_api_integration/security_and_spaces/apis/disable_legacy_url_aliases.ts @@ -5,8 +5,9 @@ * 2.0. */ -import { getTestScenarios } from '../../../saved_object_api_integration/common/lib/saved_object_test_utils'; -import type { TestUser } from '../../../saved_object_api_integration/common/lib/types'; +import { getTestScenarios } from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/saved_object_test_utils'; +import type { TestUser } from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/types'; + import type { FtrProviderContext } from '../../common/ftr_provider_context'; import { SPACES } from '../../common/lib/spaces'; import type { DisableLegacyUrlAliasesTestDefinition } from '../../common/suites/disable_legacy_url_aliases'; diff --git a/x-pack/test/spaces_api_integration/security_and_spaces/apis/get_shareable_references.ts b/x-pack/test/spaces_api_integration/security_and_spaces/apis/get_shareable_references.ts index 093e01dd8fbb..1c84d27ab77d 100644 --- a/x-pack/test/spaces_api_integration/security_and_spaces/apis/get_shareable_references.ts +++ b/x-pack/test/spaces_api_integration/security_and_spaces/apis/get_shareable_references.ts @@ -5,8 +5,9 @@ * 2.0. */ -import { getTestScenarios } from '../../../saved_object_api_integration/common/lib/saved_object_test_utils'; -import type { TestUser } from '../../../saved_object_api_integration/common/lib/types'; +import { getTestScenarios } from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/saved_object_test_utils'; +import type { TestUser } from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/types'; + import type { FtrProviderContext } from '../../common/ftr_provider_context'; import { SPACES } from '../../common/lib/spaces'; import type { diff --git a/x-pack/test/spaces_api_integration/security_and_spaces/apis/update_objects_spaces.ts b/x-pack/test/spaces_api_integration/security_and_spaces/apis/update_objects_spaces.ts index ab7e4db5908f..d595e19e0d05 100644 --- a/x-pack/test/spaces_api_integration/security_and_spaces/apis/update_objects_spaces.ts +++ b/x-pack/test/spaces_api_integration/security_and_spaces/apis/update_objects_spaces.ts @@ -8,8 +8,9 @@ import { getTestScenarios, testCaseFailures, -} from '../../../saved_object_api_integration/common/lib/saved_object_test_utils'; -import type { TestUser } from '../../../saved_object_api_integration/common/lib/types'; +} from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/saved_object_test_utils'; +import type { TestUser } from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/types'; + import type { FtrProviderContext } from '../../common/ftr_provider_context'; import { MULTI_NAMESPACE_SAVED_OBJECT_TEST_CASES as CASES } from '../../common/lib/saved_object_test_cases'; import { SPACES } from '../../common/lib/spaces'; diff --git a/x-pack/test/spaces_api_integration/spaces_only/apis/get_shareable_references.ts b/x-pack/test/spaces_api_integration/spaces_only/apis/get_shareable_references.ts index 15fef24ad0d6..302caecfae0d 100644 --- a/x-pack/test/spaces_api_integration/spaces_only/apis/get_shareable_references.ts +++ b/x-pack/test/spaces_api_integration/spaces_only/apis/get_shareable_references.ts @@ -5,7 +5,8 @@ * 2.0. */ -import { getTestScenarios } from '../../../saved_object_api_integration/common/lib/saved_object_test_utils'; +import { getTestScenarios } from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/saved_object_test_utils'; + import type { FtrProviderContext } from '../../common/ftr_provider_context'; import { SPACES } from '../../common/lib/spaces'; import type { GetShareableReferencesTestCase } from '../../common/suites/get_shareable_references'; diff --git a/x-pack/test/spaces_api_integration/spaces_only/apis/update_objects_spaces.ts b/x-pack/test/spaces_api_integration/spaces_only/apis/update_objects_spaces.ts index c45aa9edc674..77dbcdd4967a 100644 --- a/x-pack/test/spaces_api_integration/spaces_only/apis/update_objects_spaces.ts +++ b/x-pack/test/spaces_api_integration/spaces_only/apis/update_objects_spaces.ts @@ -8,7 +8,8 @@ import { getTestScenarios, testCaseFailures, -} from '../../../saved_object_api_integration/common/lib/saved_object_test_utils'; +} from '@kbn/test-suites-xpack-platform/saved_object_api_integration/common/lib/saved_object_test_utils'; + import type { FtrProviderContext } from '../../common/ftr_provider_context'; import { MULTI_NAMESPACE_SAVED_OBJECT_TEST_CASES as CASES } from '../../common/lib/saved_object_test_cases'; import { SPACES } from '../../common/lib/spaces'; diff --git a/x-pack/test/tsconfig.json b/x-pack/test/tsconfig.json index b181678fc82a..8fcf206ea70c 100644 --- a/x-pack/test/tsconfig.json +++ b/x-pack/test/tsconfig.json @@ -11,10 +11,6 @@ }, "include": [ "**/*", - "./api_integration/apis/logstash/pipeline/fixtures/*.json", - "./api_integration/apis/logstash/pipelines/fixtures/*.json", - "./api_integration/apis/telemetry/fixtures/*.json", - "./monitoring_api_integration/fixtures/**/*.json", "../../typings/**/*", "../../src/platform/packages/shared/kbn-test/types/ftr_globals/**/*" ], @@ -45,22 +41,18 @@ "@kbn/event-log-plugin", "@kbn/features-plugin", "@kbn/global-search-plugin", - "@kbn/index-management-plugin", "@kbn/infra-plugin", "@kbn/licensing-plugin", "@kbn/ml-plugin", - "@kbn/monitoring-plugin", "@kbn/observability-plugin", "@kbn/security-plugin", "@kbn/security-solution-plugin", - "@kbn/snapshot-restore-plugin", "@kbn/spaces-plugin", "@kbn/task-manager-plugin", "@kbn/transform-plugin", "@kbn/triggers-actions-ui-plugin", "@kbn/upgrade-assistant-plugin", "@kbn/remote-clusters-plugin", - "@kbn/cross-cluster-replication-plugin", "@kbn/synthetics-plugin", "@kbn/global-search-test-plugin", "@kbn/test", @@ -101,7 +93,6 @@ "@kbn/core-provider-plugin", "@kbn/user-profile-components", "@kbn/apm-synthtrace-client", - "@kbn/utils", "@kbn/journeys", "@kbn/alerting-api-integration-helpers", "@kbn/cloud-security-posture-plugin", @@ -172,7 +163,6 @@ "@kbn/palettes", "@kbn/sse-utils-server", "@kbn/gen-ai-functional-testing", - "@kbn/automatic-import-plugin", "@kbn/core-elasticsearch-server", "@kbn/streams-schema", "@kbn/server-route-repository-utils", @@ -186,6 +176,7 @@ "@kbn/content-packs-schema", "@kbn/lock-manager", "@kbn/alerts-ui-shared", - "@kbn/test-suites-xpack-observability" + "@kbn/test-suites-xpack-observability", + "@kbn/test-suites-xpack-platform" ] } diff --git a/x-pack/test_serverless/api_integration/services/index.ts b/x-pack/test_serverless/api_integration/services/index.ts index 22ce9b3bb479..bf6815ba19d9 100644 --- a/x-pack/test_serverless/api_integration/services/index.ts +++ b/x-pack/test_serverless/api_integration/services/index.ts @@ -61,3 +61,5 @@ export type InheritedServices = InheritedFtrProviderContext extends GenericFtrPr > ? TServices : {}; + +export type { SupertestWithRoleScopeType } from '../../shared/services'; diff --git a/x-pack/test_serverless/api_integration/test_suites/common/core/ui_settings.ts b/x-pack/test_serverless/api_integration/test_suites/common/core/ui_settings.ts index a359c0de62db..dd8744d18740 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/core/ui_settings.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/core/ui_settings.ts @@ -6,7 +6,7 @@ */ import expect from '@kbn/expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; // To test setting validations we are using the existing 'defaultColumns' setting that is available in all serverless projects diff --git a/x-pack/test_serverless/api_integration/test_suites/common/data_usage/tests/data_streams.ts b/x-pack/test_serverless/api_integration/test_suites/common/data_usage/tests/data_streams.ts index e591d23b125e..322a568bdd6c 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/data_usage/tests/data_streams.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/data_usage/tests/data_streams.ts @@ -8,14 +8,14 @@ import expect from '@kbn/expect'; import { DataStreamsResponseBodySchemaBody } from '@kbn/data-usage-plugin/common/rest_types'; import { DATA_USAGE_DATA_STREAMS_API_ROUTE } from '@kbn/data-usage-plugin/common'; -import { SupertestWithRoleScope } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services/role_scoped_supertest'; +import { SupertestWithRoleScopeType } from '../../../../services'; import { FtrProviderContext } from '../../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { const svlDatastreamsHelpers = getService('svlDatastreamsHelpers'); const roleScopedSupertest = getService('roleScopedSupertest'); const retry = getService('retry'); - let supertestAdminWithCookieCredentials: SupertestWithRoleScope; + let supertestAdminWithCookieCredentials: SupertestWithRoleScopeType; const testDataStreamName = 'test-data-stream'; describe(`GET ${DATA_USAGE_DATA_STREAMS_API_ROUTE}`, function () { this.tags(['skipMKI']); diff --git a/x-pack/test_serverless/api_integration/test_suites/common/data_usage/tests/metrics.ts b/x-pack/test_serverless/api_integration/test_suites/common/data_usage/tests/metrics.ts index 6a0774ea2e8f..8dc7480023fe 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/data_usage/tests/metrics.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/data_usage/tests/metrics.ts @@ -8,10 +8,10 @@ import expect from '@kbn/expect'; import http from 'http'; -import { SupertestWithRoleScope } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services/role_scoped_supertest'; import { UsageMetricsRequestBody } from '@kbn/data-usage-plugin/common/rest_types'; import { DATA_USAGE_METRICS_API_ROUTE } from '@kbn/data-usage-plugin/common'; import { transformMetricsData } from '@kbn/data-usage-plugin/server/routes/internal/usage_metrics_handler'; +import { SupertestWithRoleScopeType } from '../../../../services'; import { FtrProviderContext } from '../../../../ftr_provider_context'; import { setupMockServer } from '../mock_api'; import { mockAutoOpsResponse } from '../mock_data'; @@ -25,7 +25,7 @@ const from = nowMinus24Hours.toISOString(); export default function ({ getService }: FtrProviderContext) { const svlDatastreamsHelpers = getService('svlDatastreamsHelpers'); const roleScopedSupertest = getService('roleScopedSupertest'); - let supertestAdminWithCookieCredentials: SupertestWithRoleScope; + let supertestAdminWithCookieCredentials: SupertestWithRoleScopeType; const mockAutoopsApiService = setupMockServer(); describe('Metrics', function () { let mockApiServer: http.Server; diff --git a/x-pack/test_serverless/api_integration/test_suites/common/index_management/create_enrich_policies.ts b/x-pack/test_serverless/api_integration/test_suites/common/index_management/create_enrich_policies.ts index a863e4f0ebc1..908679fbeab4 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/index_management/create_enrich_policies.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/index_management/create_enrich_policies.ts @@ -6,7 +6,7 @@ */ import expect from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; const INTERNAL_API_BASE_PATH = '/internal/index_management'; diff --git a/x-pack/test_serverless/api_integration/test_suites/common/index_management/indices.ts b/x-pack/test_serverless/api_integration/test_suites/common/index_management/indices.ts index 6fada3da005e..cba7b6557a80 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/index_management/indices.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/index_management/indices.ts @@ -6,7 +6,7 @@ */ import expect from '@kbn/expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { RoleCredentials } from '../../../../shared/services'; import { FtrProviderContext } from '../../../ftr_provider_context'; diff --git a/x-pack/test_serverless/api_integration/test_suites/common/kql_telemetry/kql_telemetry.ts b/x-pack/test_serverless/api_integration/test_suites/common/kql_telemetry/kql_telemetry.ts index 8e0ea8cab730..bc742f6d9d1a 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/kql_telemetry/kql_telemetry.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/kql_telemetry/kql_telemetry.ts @@ -9,8 +9,8 @@ import expect from '@kbn/expect'; import { get } from 'lodash'; import { ANALYTICS_SAVED_OBJECT_INDEX } from '@kbn/core-saved-objects-server'; import { KQL_TELEMETRY_ROUTE_LATEST_VERSION } from '@kbn/data-plugin/common'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; import { ELASTIC_HTTP_VERSION_HEADER } from '@kbn/core-http-common'; +import { SupertestWithRoleScopeType } from '../../../services'; import type { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/management/spaces.ts b/x-pack/test_serverless/api_integration/test_suites/common/management/spaces.ts index 000848fd37e5..f3a583237455 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/management/spaces.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/management/spaces.ts @@ -6,8 +6,8 @@ */ import expect from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; import { asyncForEach } from '@kbn/std'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/anonymous.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/anonymous.ts index dc4cddd0d984..c63ada30a913 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/anonymous.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/anonymous.ts @@ -5,7 +5,7 @@ * 2.0. */ -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/api_keys.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/api_keys.ts index 6646e34ae849..d1bbe4b5e505 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/api_keys.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/api_keys.ts @@ -6,7 +6,7 @@ */ import expect from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/authentication.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/authentication.ts index 644f0c5b852a..7233318dda59 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/authentication.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/authentication.ts @@ -6,7 +6,7 @@ */ import expect from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/authorization.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/authorization.ts index 398c591414f9..34134b8abdf4 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/authorization.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/authorization.ts @@ -7,8 +7,8 @@ import expect from 'expect'; import { KibanaFeatureConfig, SubFeaturePrivilegeConfig } from '@kbn/features-plugin/common'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; import type { Role } from '@kbn/security-plugin-types-common'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; /* diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/feature_check.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/feature_check.ts index 97922157dab3..a552aade6ab2 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/feature_check.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/feature_check.ts @@ -5,7 +5,7 @@ * 2.0. */ -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/misc.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/misc.ts index 46615e3c7a0d..93dd03bab401 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/misc.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/misc.ts @@ -6,7 +6,7 @@ */ import expect from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/response_headers.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/response_headers.ts index ea37efd75d6d..8f915f6bd822 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/response_headers.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/response_headers.ts @@ -7,7 +7,7 @@ import expect from 'expect'; import cspParser from 'content-security-policy-parser'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/role_mappings.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/role_mappings.ts index b5b51dcef569..6b6595c1dc2c 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/role_mappings.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/role_mappings.ts @@ -5,7 +5,7 @@ * 2.0. */ -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/sessions.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/sessions.ts index c102f502f948..741b71115076 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/sessions.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/sessions.ts @@ -6,7 +6,7 @@ */ import expect from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/user_profiles.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/user_profiles.ts index 481e5d9394d2..46f5c8755c28 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/user_profiles.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/user_profiles.ts @@ -7,7 +7,7 @@ import expect from 'expect'; import { kibanaTestUser } from '@kbn/test'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/users.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/users.ts index 58d8e1b6eee9..86e0ea273bd7 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/users.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/users.ts @@ -6,7 +6,7 @@ */ import expect from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/views.ts b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/views.ts index 8234fa61113d..fc6060c98fb1 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/platform_security/views.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/platform_security/views.ts @@ -6,7 +6,7 @@ */ import expect from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/scripts_tests/languages.ts b/x-pack/test_serverless/api_integration/test_suites/common/scripts_tests/languages.ts index 93a0359bfe2c..02afd0e02dd5 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/scripts_tests/languages.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/scripts_tests/languages.ts @@ -9,7 +9,7 @@ import expect from '@kbn/expect'; import { ELASTIC_HTTP_VERSION_HEADER } from '@kbn/core-http-common'; import { SCRIPT_LANGUAGES_ROUTE_LATEST_VERSION } from '@kbn/data-plugin/common/constants'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/common/search_oss/search.ts b/x-pack/test_serverless/api_integration/test_suites/common/search_oss/search.ts index 8bd492c5e94f..157837c89f0d 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/search_oss/search.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/search_oss/search.ts @@ -7,7 +7,7 @@ import { ELASTIC_HTTP_VERSION_HEADER } from '@kbn/core-http-common'; import expect from '@kbn/expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import type { FtrProviderContext } from '../../../ftr_provider_context'; import { painlessErrReq } from './painless_err_req'; import { verifyErrorResponse } from './verify_error'; diff --git a/x-pack/test_serverless/api_integration/test_suites/common/telemetry/telemetry_config.ts b/x-pack/test_serverless/api_integration/test_suites/common/telemetry/telemetry_config.ts index 6819dd0c0e8f..36d362fb55a9 100644 --- a/x-pack/test_serverless/api_integration/test_suites/common/telemetry/telemetry_config.ts +++ b/x-pack/test_serverless/api_integration/test_suites/common/telemetry/telemetry_config.ts @@ -7,7 +7,7 @@ import expect from '@kbn/expect'; import { expect as externalExpect } from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function telemetryConfigTest({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/observability/ai_assistant/common/observability_ai_assistant_api_client.ts b/x-pack/test_serverless/api_integration/test_suites/observability/ai_assistant/common/observability_ai_assistant_api_client.ts index 566d06702872..061175872380 100644 --- a/x-pack/test_serverless/api_integration/test_suites/observability/ai_assistant/common/observability_ai_assistant_api_client.ts +++ b/x-pack/test_serverless/api_integration/test_suites/observability/ai_assistant/common/observability_ai_assistant_api_client.ts @@ -15,8 +15,7 @@ import supertest from 'supertest'; import { Subtract } from 'utility-types'; import { format } from 'url'; import { Config } from '@kbn/test'; -import { SupertestWithRoleScope } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services/role_scoped_supertest'; -import { InheritedFtrProviderContext } from '../../../../services'; +import { InheritedFtrProviderContext, SupertestWithRoleScopeType } from '../../../../services'; import type { InternalRequestHeader, RoleCredentials } from '../../../../../shared/services'; export function getObservabilityAIAssistantApiClient({ @@ -24,7 +23,7 @@ export function getObservabilityAIAssistantApiClient({ supertestUserWithCookieCredentials, }: { svlSharedConfig: Config; - supertestUserWithCookieCredentials?: SupertestWithRoleScope; + supertestUserWithCookieCredentials?: SupertestWithRoleScopeType; }) { if (supertestUserWithCookieCredentials) { return createObservabilityAIAssistantApiClient(supertestUserWithCookieCredentials); @@ -52,7 +51,7 @@ export type ObservabilityAIAssistantApiClient = Record< >; export function createObservabilityAIAssistantApiClient( - st: SupertestWithRoleScope | supertest.Agent + st: SupertestWithRoleScopeType | supertest.Agent ) { return ( options: { @@ -200,21 +199,21 @@ export async function getObservabilityAIAssistantApiClientService({ const roleScopedSupertest = getService('roleScopedSupertest'); // admin user - const supertestAdminWithCookieCredentials: SupertestWithRoleScope = + const supertestAdminWithCookieCredentials: SupertestWithRoleScopeType = await roleScopedSupertest.getSupertestWithRoleScope('admin', { useCookieHeader: true, withInternalHeaders: true, }); // editor user - const supertestEditorWithCookieCredentials: SupertestWithRoleScope = + const supertestEditorWithCookieCredentials: SupertestWithRoleScopeType = await roleScopedSupertest.getSupertestWithRoleScope('editor', { useCookieHeader: true, withInternalHeaders: true, }); // unauthorized user - const supertestUnauthorizedWithCookieCredentials: SupertestWithRoleScope = + const supertestUnauthorizedWithCookieCredentials: SupertestWithRoleScopeType = await roleScopedSupertest.getSupertestWithRoleScope('viewer', { useCookieHeader: false, withInternalHeaders: true, diff --git a/x-pack/test_serverless/api_integration/test_suites/search/search_indices/indices.ts b/x-pack/test_serverless/api_integration/test_suites/search/search_indices/indices.ts index ba75d1334f4f..9519ce10fb62 100644 --- a/x-pack/test_serverless/api_integration/test_suites/search/search_indices/indices.ts +++ b/x-pack/test_serverless/api_integration/test_suites/search/search_indices/indices.ts @@ -6,7 +6,7 @@ */ import expect from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; const INTERNAL_API_BASE_PATH = '/internal/search_indices'; diff --git a/x-pack/test_serverless/api_integration/test_suites/search/search_indices/status.ts b/x-pack/test_serverless/api_integration/test_suites/search/search_indices/status.ts index e92cc6229684..2fbde40cf09a 100644 --- a/x-pack/test_serverless/api_integration/test_suites/search/search_indices/status.ts +++ b/x-pack/test_serverless/api_integration/test_suites/search/search_indices/status.ts @@ -6,7 +6,7 @@ */ import expect from 'expect'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService }: FtrProviderContext) { diff --git a/x-pack/test_serverless/api_integration/test_suites/search/search_playground/playgrounds.ts b/x-pack/test_serverless/api_integration/test_suites/search/search_playground/playgrounds.ts index a340abeabb03..6411fb284627 100644 --- a/x-pack/test_serverless/api_integration/test_suites/search/search_playground/playgrounds.ts +++ b/x-pack/test_serverless/api_integration/test_suites/search/search_playground/playgrounds.ts @@ -7,7 +7,7 @@ import expect from 'expect'; import { ELASTIC_HTTP_VERSION_HEADER } from '@kbn/core-http-common'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; const INTERNAL_API_BASE_PATH = '/internal/search_playground/playgrounds'; diff --git a/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/api_key.ts b/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/api_key.ts index 9c8cca9900c9..99bc2d58d031 100644 --- a/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/api_key.ts +++ b/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/api_key.ts @@ -8,7 +8,7 @@ import expect from 'expect'; import { kibanaTestSuperuserServerless } from '@kbn/test'; import { SecurityApiKey } from '@elastic/elasticsearch/lib/api/types'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; const API_BASE_PATH = '/internal/serverless_search'; diff --git a/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/connectors.ts b/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/connectors.ts index c45b5171fcec..7e9e7634c968 100644 --- a/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/connectors.ts +++ b/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/connectors.ts @@ -6,14 +6,14 @@ */ import expect from 'expect'; -import { SupertestWithRoleScope } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services/role_scoped_supertest'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; const API_BASE_PATH = '/internal/serverless_search'; export default function ({ getService }: FtrProviderContext) { const roleScopedSupertest = getService('roleScopedSupertest'); - let supertestDeveloperWithCookieCredentials: SupertestWithRoleScope; + let supertestDeveloperWithCookieCredentials: SupertestWithRoleScopeType; describe('Connectors routes', function () { describe('GET connectors', function () { diff --git a/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/indices.ts b/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/indices.ts index 35c61f354892..9e98143ac4f3 100644 --- a/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/indices.ts +++ b/x-pack/test_serverless/api_integration/test_suites/search/serverless_search/indices.ts @@ -6,14 +6,14 @@ */ import expect from 'expect'; -import { SupertestWithRoleScope } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services/role_scoped_supertest'; +import { SupertestWithRoleScopeType } from '../../../services'; import { FtrProviderContext } from '../../../ftr_provider_context'; const API_BASE_PATH = '/internal/serverless_search'; export default function ({ getService }: FtrProviderContext) { const roleScopedSupertest = getService('roleScopedSupertest'); - let supertestViewerWithCookieCredentials: SupertestWithRoleScope; + let supertestViewerWithCookieCredentials: SupertestWithRoleScopeType; describe('Indices routes', function () { describe('GET indices', function () { diff --git a/x-pack/test_serverless/api_integration/test_suites/security/cloud_security_posture/telemetry.ts b/x-pack/test_serverless/api_integration/test_suites/security/cloud_security_posture/telemetry.ts index 15700419a7e9..d0f2e02347a7 100644 --- a/x-pack/test_serverless/api_integration/test_suites/security/cloud_security_posture/telemetry.ts +++ b/x-pack/test_serverless/api_integration/test_suites/security/cloud_security_posture/telemetry.ts @@ -13,7 +13,7 @@ import { waitForPluginInitialized, EsIndexDataProvider, } from '@kbn/test-suites-xpack/cloud_security_posture_api/utils'; -import { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { SupertestWithRoleScopeType } from '../../../services'; import type { FtrProviderContext } from '../../../ftr_provider_context'; import { RoleCredentials } from '../../../../shared/services'; diff --git a/x-pack/test_serverless/shared/services/deployment_agnostic_services.ts b/x-pack/test_serverless/shared/services/deployment_agnostic_services.ts index fa9a1671871a..0e11b3b10c25 100644 --- a/x-pack/test_serverless/shared/services/deployment_agnostic_services.ts +++ b/x-pack/test_serverless/shared/services/deployment_agnostic_services.ts @@ -5,35 +5,44 @@ * 2.0. */ -import _ from 'lodash'; - import { services as apiIntegrationServices } from '@kbn/test-suites-xpack/api_integration/services'; import { services as apiIntegrationDeploymentAgnosticServices } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; -/* - * Some FTR services from api integration stateful tests are compatible with serverless environment - * While adding a new one, make sure to verify that it works on both Kibana CI and MKI - */ -const pickedServices = _.pick(apiIntegrationServices, [ - 'deployment', - 'es', - 'esArchiver', - 'esDeleteAllIndices', - 'esSupertest', - 'indexPatterns', - 'ingestPipelines', - 'indexManagement', - 'kibanaServer', - 'ml', - 'randomness', - 'retry', - 'security', - 'usageAPI', - 'console', - 'securitySolutionApi', -]); +import { commonFunctionalServices } from '@kbn/ftr-common-functional-services'; +import { SecuritySolutionApiProvider } from '@kbn/test-suites-xpack/api_integration/services/security_solution_api.gen'; +import { services as platformApiIntegrationServices } from '@kbn/test-suites-xpack-platform/api_integration/services'; + +// pick only services that work for any FTR config, e.g. 'samlAuth' requires SAML setup in config file +const { + es, + esArchiver, + kibanaServer, + retry, + deployment, + randomness, + esDeleteAllIndices, + indexPatterns, + console, + esSupertest, + security, +} = commonFunctionalServices; export const services = { // deployment agnostic FTR services - ...pickedServices, + deployment, + es, + esArchiver, + esDeleteAllIndices, + esSupertest, + indexPatterns, + ingestPipelines: platformApiIntegrationServices.ingestPipelines, + indexManagement: platformApiIntegrationServices.indexManagement, + kibanaServer, + ml: apiIntegrationServices.ml, + randomness, + retry, + security, + usageAPI: platformApiIntegrationServices.usageAPI, + console, + securitySolutionApi: SecuritySolutionApiProvider, alertingApi: apiIntegrationDeploymentAgnosticServices.alertingApi, }; diff --git a/x-pack/test_serverless/shared/services/index.ts b/x-pack/test_serverless/shared/services/index.ts index 9e98e6f41101..4c5ad896ddcd 100644 --- a/x-pack/test_serverless/shared/services/index.ts +++ b/x-pack/test_serverless/shared/services/index.ts @@ -6,7 +6,7 @@ */ import { commonFunctionalServices } from '@kbn/ftr-common-functional-services'; -import { services as deploymentAgnosticServices } from '@kbn/test-suites-xpack/api_integration/deployment_agnostic/services'; +import { services as commonDeploymentAgnosticServices } from '@kbn/test-suites-xpack-platform/api_integration_deployment_agnostic/services'; import { SupertestProvider } from './supertest'; import { SvlCommonApiServiceProvider } from './svl_common_api'; import { SvlReportingServiceProvider } from './svl_reporting'; @@ -28,8 +28,10 @@ export const services = { svlReportingApi: SvlReportingServiceProvider, svlUserManager: commonFunctionalServices.samlAuth, samlAuth: commonFunctionalServices.samlAuth, // <--temp workaround until we can unify naming - roleScopedSupertest: deploymentAgnosticServices.roleScopedSupertest, - customRoleScopedSupertest: deploymentAgnosticServices.customRoleScopedSupertest, + roleScopedSupertest: commonDeploymentAgnosticServices.roleScopedSupertest, + customRoleScopedSupertest: commonDeploymentAgnosticServices.customRoleScopedSupertest, dataViewApi: DataViewApiProvider, platformSecurityUtils: PlatformSecurityUtilsProvider, }; + +export type { SupertestWithRoleScopeType } from '@kbn/test-suites-xpack-platform/api_integration_deployment_agnostic/services'; diff --git a/x-pack/test_serverless/tsconfig.json b/x-pack/test_serverless/tsconfig.json index 06031c1789ef..82a19b6e7858 100644 --- a/x-pack/test_serverless/tsconfig.json +++ b/x-pack/test_serverless/tsconfig.json @@ -90,5 +90,6 @@ "@kbn/data-usage-plugin", "@kbn/scout-info", "@kbn/streams-schema", + "@kbn/test-suites-xpack-platform", ] } diff --git a/yarn.lock b/yarn.lock index bed7fa90f5c7..fca1f7cc552f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6832,7 +6832,7 @@ version "0.0.0" uid "" -"@kbn/saved-object-test-plugin@link:x-pack/test/saved_object_api_integration/common/plugins/saved_object_test_plugin": +"@kbn/saved-object-test-plugin@link:x-pack/platform/test/saved_object_api_integration/common/plugins/saved_object_test_plugin": version "0.0.0" uid ""