diff options
Diffstat (limited to 'bigtop-tests/smoke-tests/odpi-runtime/build.gradle')
-rw-r--r-- | bigtop-tests/smoke-tests/odpi-runtime/build.gradle | 63 |
1 files changed, 63 insertions, 0 deletions
diff --git a/bigtop-tests/smoke-tests/odpi-runtime/build.gradle b/bigtop-tests/smoke-tests/odpi-runtime/build.gradle new file mode 100644 index 00000000..97e36353 --- /dev/null +++ b/bigtop-tests/smoke-tests/odpi-runtime/build.gradle @@ -0,0 +1,63 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF 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 + * <p/> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p/> + * 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. + */ +def junitVersion = '4.11' + +apply plugin: 'java' + +repositories { + maven { + url "http://conjars.org/repo/" + } +} +dependencies { + compile group: 'junit', name: 'junit', version: junitVersion, transitive: 'true' + compile group: 'commons-logging', name: 'commons-logging', version: '1.1.3' + compile group: 'org.apache.commons', name: 'commons-exec', version: '1.3' + compile group: 'org.apache.hive', name: 'hive-jdbc', version: '1.2.1' + compile group: 'org.apache.hive', name: 'hive-metastore', version: '1.2.1' + compile group: 'org.apache.hive', name: 'hive-common', version: '1.2.1' + compile group: 'org.apache.thrift', name: 'libfb303', version: '0.9.3' + compile group: 'org.apache.thrift', name: 'libthrift', version: '0.9.3' + compile group: 'org.apache.hadoop', name: 'hadoop-common', version: '2.7.2' + compile group: 'org.apache.hive.hcatalog', name: 'hive-hcatalog-core', version: '1.2.1' + testCompile group: 'org.apache.hadoop', name: 'hadoop-mapreduce-client-core', version: '2.7.2' + compile group: 'org.apache.hadoop', name: 'hadoop-mapreduce-client-jobclient', version: '2.7.2' + testCompile group: 'org.apache.hadoop', name: 'hadoop-mapreduce-client-common', version: '2.7.2' + testCompile group: 'org.apache.hadoop', name: 'hadoop-hdfs', version: '2.7.2' + testCompile group: 'org.apache.hive', name: 'hive-exec', version: '1.2.1' + testCompile "junit:junit:4.11" + if (System.env.HADOOP_CONF_DIR) testRuntime files(System.env.HADOOP_CONF_DIR) +} + +jar { + from { + (configurations.runtime).grep{it.toString() =~ /(hive|libfb303)-.*[jw]ar$/}.collect { + zipTree(it) + } + } + + exclude 'META-INF/*.RSA', 'META-INF/*.SF','META-INF/*.DSA' +} + +test { + // Change the default location where test data is picked up + systemProperty 'test.resources.dir', "${buildDir}/resources/test/" + systemProperty 'odpi.test.hive.hcat.job.jar', jar.archivePath + systemProperty 'odpi.test.hive.hcat.core.jar', (configurations.runtime).find { it.toString() =~ /hive-hcatalog-core-.*jar$/ } +} +test.dependsOn jar |