2015-10-30 02:25:24 -04:00
|
|
|
/*
|
|
|
|
* Licensed to Elasticsearch under one or more contributor
|
|
|
|
* license agreements. See the NOTICE file distributed with
|
|
|
|
* this work for additional information regarding copyright
|
|
|
|
* ownership. Elasticsearch licenses this file to you under
|
|
|
|
* the Apache License, Version 2.0 (the "License"); you may
|
|
|
|
* not use this file except in compliance with the License.
|
|
|
|
* You may obtain a copy of the License at
|
|
|
|
*
|
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
*
|
|
|
|
* Unless required by applicable law or agreed to in writing,
|
|
|
|
* software distributed under the License is distributed on an
|
|
|
|
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
|
|
* KIND, either express or implied. See the License for the
|
|
|
|
* specific language governing permissions and limitations
|
|
|
|
* under the License.
|
|
|
|
*/
|
2020-05-11 03:39:13 -04:00
|
|
|
import org.elasticsearch.gradle.info.BuildParams;
|
2018-12-05 07:20:01 -05:00
|
|
|
|
2015-10-29 14:40:19 -04:00
|
|
|
dependencies {
|
2020-06-30 09:57:41 -04:00
|
|
|
api project(":client:rest")
|
|
|
|
api project(":client:sniffer")
|
|
|
|
api project(':libs:elasticsearch-nio')
|
|
|
|
api project(":server")
|
|
|
|
api project(":libs:elasticsearch-cli")
|
|
|
|
api "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}"
|
|
|
|
api "junit:junit:${versions.junit}"
|
|
|
|
api "org.hamcrest:hamcrest:${versions.hamcrest}"
|
|
|
|
api "org.apache.lucene:lucene-test-framework:${versions.lucene}"
|
|
|
|
api "org.apache.lucene:lucene-codecs:${versions.lucene}"
|
|
|
|
api "commons-logging:commons-logging:${versions.commonslogging}"
|
|
|
|
api "commons-codec:commons-codec:${versions.commonscodec}"
|
|
|
|
api "org.elasticsearch:securemock:${versions.securemock}"
|
|
|
|
api "org.elasticsearch:mocksocket:${versions.mocksocket}"
|
2015-10-29 14:40:19 -04:00
|
|
|
}
|
|
|
|
|
2019-04-05 02:01:56 -04:00
|
|
|
compileJava.options.compilerArgs << '-Xlint:-cast,-rawtypes,-unchecked'
|
2015-10-30 02:25:24 -04:00
|
|
|
compileTestJava.options.compilerArgs << '-Xlint:-rawtypes'
|
2015-10-29 14:40:19 -04:00
|
|
|
|
2016-03-09 13:01:15 -05:00
|
|
|
// the main files are actually test files, so use the appropriate forbidden api sigs
|
2020-04-15 16:23:55 -04:00
|
|
|
tasks.named('forbiddenApisMain').configure {
|
2018-08-22 02:05:22 -04:00
|
|
|
replaceSignatureFiles 'jdk-signatures', 'es-all-signatures', 'es-test-signatures'
|
2015-12-28 22:38:55 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
// TODO: should we have licenses for our test deps?
|
2020-06-18 02:15:50 -04:00
|
|
|
tasks.named("dependencyLicenses").configure { it.enabled = false }
|
2017-12-26 04:51:47 -05:00
|
|
|
dependenciesInfo.enabled = false
|
2015-12-28 22:38:55 -05:00
|
|
|
|
2019-11-14 06:01:23 -05:00
|
|
|
thirdPartyAudit.ignoreMissingClasses(
|
2015-12-28 22:38:55 -05:00
|
|
|
// classes are missing
|
2016-06-22 13:40:01 -04:00
|
|
|
'javax.servlet.ServletContextEvent',
|
|
|
|
'javax.servlet.ServletContextListener',
|
|
|
|
'org.apache.avalon.framework.logger.Logger',
|
|
|
|
'org.apache.log.Hierarchy',
|
2019-05-30 16:06:11 -04:00
|
|
|
'org.apache.log.Logger',
|
|
|
|
'org.apache.log4j.Category',
|
|
|
|
'org.apache.log4j.Level',
|
|
|
|
'org.apache.log4j.Logger',
|
|
|
|
'org.apache.log4j.Priority'
|
2019-01-07 10:24:19 -05:00
|
|
|
)
|
2017-04-25 21:11:47 -04:00
|
|
|
|
2019-04-09 14:52:50 -04:00
|
|
|
test {
|
2020-05-11 03:39:13 -04:00
|
|
|
systemProperty 'tests.gradle_index_compat_versions', BuildParams.bwcVersions.indexCompatible.join(',')
|
|
|
|
systemProperty 'tests.gradle_wire_compat_versions', BuildParams.bwcVersions.wireCompatible.join(',')
|
|
|
|
systemProperty 'tests.gradle_unreleased_versions', BuildParams.bwcVersions.unreleased.join(',')
|
2017-06-02 21:30:47 -04:00
|
|
|
}
|
2018-12-05 07:20:01 -05:00
|
|
|
|
2019-04-09 14:52:50 -04:00
|
|
|
task integTest(type: Test) {
|
2018-12-05 07:20:01 -05:00
|
|
|
include "**/*IT.class"
|
|
|
|
}
|
2019-10-10 04:23:24 -04:00
|
|
|
|
|
|
|
tasks.register("verifyVersions") {
|
2019-11-14 06:01:23 -05:00
|
|
|
dependsOn test
|
2019-10-10 04:23:24 -04:00
|
|
|
}
|