build.gradle 4.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. apply plugin: 'elasticsearch.internal-yaml-rest-test'
  2. import org.elasticsearch.gradle.util.GradleUtils
  3. dependencies {
  4. testImplementation project(':x-pack:qa')
  5. testImplementation project(':x-pack:qa:multi-project:yaml-test-framework')
  6. clusterModules project(':modules:mapper-extras')
  7. clusterModules project(':modules:rank-eval')
  8. clusterModules project(':modules:ingest-common')
  9. clusterModules project(':modules:reindex')
  10. clusterModules project(':modules:analysis-common')
  11. clusterModules project(':modules:health-shards-availability')
  12. clusterModules project(':modules:data-streams')
  13. clusterModules project(':modules:lang-mustache')
  14. clusterModules project(':modules:parent-join')
  15. clusterModules project(xpackModule('stack'))
  16. clusterModules project(xpackModule('ilm'))
  17. clusterModules project(xpackModule('mapper-constant-keyword'))
  18. clusterModules project(xpackModule('wildcard'))
  19. clusterModules project(':test:external-modules:test-multi-project')
  20. restTestConfig project(path: ':modules:data-streams', configuration: "basicRestSpecs")
  21. restTestConfig project(path: ':modules:ingest-common', configuration: "basicRestSpecs")
  22. restTestConfig project(path: ':modules:reindex', configuration: "basicRestSpecs")
  23. }
  24. // let the yamlRestTests see the classpath of test
  25. GradleUtils.extendSourceSet(project, "test", "yamlRestTest", tasks.named("yamlRestTest"))
  26. restResources {
  27. restTests {
  28. includeCore '*'
  29. }
  30. }
  31. tasks.named("yamlRestTest").configure {
  32. ArrayList<String> blacklist = [
  33. /* These tests don't work on multi-project yet - we need to go through each of them and make them work */
  34. '^cat.recovery/*/*',
  35. '^cat.snapshots/*/*',
  36. '^cluster.desired_balance/10_basic/*',
  37. '^data_stream/10_basic/Get data stream and check DSL and ILM information',
  38. '^data_stream/40_supported_apis/Verify shard stores api', // uses _shard_stores API
  39. '^health/10_basic/*',
  40. '^health/40_diagnosis/*',
  41. '^indices.get_alias/10_basic/Get alias against closed indices', // Does NOT work with security enabled, see also core-rest-tests-with-security
  42. '^indices.recovery/*/*',
  43. '^indices.resolve_cluster/*/*',
  44. '^indices.resolve_cluster/*/*/*',
  45. '^indices.shard_stores/*/*',
  46. '^test/ingest/15_info_ingest/*', // uses cluster info API
  47. '^test/ingest/70_bulk/Test bulk request with default pipeline', // uses stats API
  48. '^test/ingest/70_bulk/Test bulk request without default pipeline', // uses stats API
  49. '^migration/*/*',
  50. // The following vector search tests do not work due to usage of cluster stats API
  51. '^search.vectors/60_dense_vector_dynamic_mapping/Fields mapped as dense_vector have correct cluster stats min max values',
  52. '^search.vectors/60_dense_vector_dynamic_mapping/Fields mapped as dense_vector without dims or docs have correct cluster stats values',
  53. '^search.vectors/70_dense_vector_telemetry/Field mapping stats',
  54. '^search.vectors/70_dense_vector_telemetry/Field mapping stats with field details',
  55. '^snapshot.clone/*/*',
  56. '^snapshot.create/*/*',
  57. '^snapshot.delete/*/*',
  58. '^snapshot.get/*/*',
  59. '^snapshot.get_repository/20_repository_uuid/*',
  60. '^snapshot.restore/*/*',
  61. '^snapshot.status/*/*',
  62. '^synonyms/*/*',
  63. '^tsdb/30_snapshot/*',
  64. '^update_by_query/80_scripting/Update all docs with one deletion and one noop using a stored script', // scripting is not project aware yet
  65. // The following tests are muted because the functionality that they are testing is not available in a multi-project setup
  66. // The node removal prevalidation is only available for a Stateful deployment.
  67. '^cluster.prevalidate_node_removal/*/*',
  68. // This behaviour doesn't work with security: https://github.com/elastic/elasticsearch/issues/120252
  69. '^reindex/30_search/Sorting deprecated wait_for_completion false',
  70. // These tests assume we are running on a single node
  71. '^delete_by_query/50_wait_for_active_shards/can override wait_for_active_shards',
  72. '^update_by_query/50_consistency/can override wait_for_active_shards',
  73. // Reindex from remote is not supported on Serverless and required additional testing setup
  74. '^reindex/60_wait_for_active_shards/can override wait_for_active_shards', // <- Requires a single shard
  75. '^reindex/90_remote/*',
  76. '^reindex/95_parent_join/Reindex from remote*'
  77. ];
  78. if (buildParams.isSnapshotBuild() == false) {
  79. blacklist += [];
  80. }
  81. systemProperty 'tests.rest.blacklist', blacklist.join(',')
  82. }