/*
 * 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", the "GNU Affero General Public License v3.0 only", and the "Server Side
 * Public License v 1"; you may not use this file except in compliance with, at
 * your election, the "Elastic License 2.0", the "GNU Affero General Public
 * License v3.0 only", or the "Server Side Public License, v 1".
 */

plugins {
  id 'elasticsearch.distro-test'
}

dependencies {
  testImplementation project(':server')
  testImplementation project(':libs:core')
  testImplementation(testArtifact(project(':x-pack:plugin:core')))
  testImplementation "junit:junit:${versions.junit}"
  testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}"
  testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}"
  testImplementation "org.apache.httpcomponents:httpcore:${versions.httpcore}"
  testImplementation "org.apache.httpcomponents:httpclient:${versions.httpclient}"
  testImplementation "org.apache.httpcomponents:fluent-hc:${versions.httpclient}"
  testImplementation "org.apache.logging.log4j:log4j-api:${versions.log4j}"
  testImplementation "org.apache.logging.log4j:log4j-core:${versions.log4j}"
  testImplementation "org.apache.logging.log4j:log4j-jcl:${versions.log4j}"
  testImplementation "commons-codec:commons-codec:${versions.commonscodec}"
  testImplementation "commons-logging:commons-logging:${versions.commonslogging}"
  testImplementation "com.fasterxml.jackson.core:jackson-annotations:${versions.jackson}"
  testImplementation "com.fasterxml.jackson.core:jackson-core:${versions.jackson}"
  testImplementation "com.fasterxml.jackson.core:jackson-databind:${versions.jackson}"
}

// we don't have additional tests for the tests themselves
tasks.named("test").configure { enabled = false }

tasks.register('destructivePackagingTest') {
  dependsOn 'destructiveDistroTest'
}
