PageRenderTime 10ms CodeModel.GetById 2ms app.highlight 5ms RepoModel.GetById 1ms app.codeStats 0ms

/tags/release-0.2.0-rc0/hive/external/contrib/build.xml

#
XML | 116 lines | 74 code | 15 blank | 27 comment | 0 complexity | f4e3c4222848a02785e4f6f90df8a2e7 MD5 | raw file
  1<?xml version="1.0"?>
  2
  3<!--
  4   Licensed to the Apache Software Foundation (ASF) under one or more
  5   contributor license agreements.  See the NOTICE file distributed with
  6   this work for additional information regarding copyright ownership.
  7   The ASF licenses this file to You under the Apache License, Version 2.0
  8   (the "License"); you may not use this file except in compliance with
  9   the License.  You may obtain a copy of the License at
 10
 11       http://www.apache.org/licenses/LICENSE-2.0
 12
 13   Unless required by applicable law or agreed to in writing, software
 14   distributed under the License is distributed on an "AS IS" BASIS,
 15   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 16   See the License for the specific language governing permissions and
 17   limitations under the License.
 18-->
 19
 20
 21<project name="contrib" default="jar">
 22
 23  <property name="contrib.lib.dir" value="${basedir}/lib"/>
 24  <property name="src.dir"  location="${basedir}/src/java"/>
 25  <property name="contrib.test.query.dir" location="${basedir}/src/test/queries"/>
 26  <property name="ql.test.template.dir" location="${basedir}/../ql/src/test/templates"/>
 27  <property name="contrib.test.results.dir" location="${basedir}/src/test/results"/>
 28
 29  <import file="../build-common.xml"/>
 30
 31  <path id="test.classpath">
 32    <pathelement location="${build.dir.hive}/ql/test/classes" />
 33    <pathelement location="${test.build.classes}" />
 34    <pathelement location="" />
 35    <pathelement location="${hadoop.conf.dir}"/>
 36    <pathelement location="${test.src.data.dir}/conf"/>
 37    <pathelement location="${hive.conf.dir}"/>
 38    <pathelement location="${hive.root}/cli/lib/jline-0.9.94.jar"/>
 39    <pathelement location="${jetty.test.jar}"/>
 40    <pathelement location="${servlet.test.jar}"/>
 41    <pathelement location="${jasper.test.jar}"/>
 42    <pathelement location="${jasperc.test.jar}"/>
 43    <pathelement location="${jsp.test.jar}"/>
 44    <pathelement location="${common.jar}"/>
 45    <fileset dir="${hive.root}" includes="testlibs/*.jar"/>
 46    <fileset dir="${hadoop.root}/lib" includes="*.jar"/>
 47    <path refid="classpath"/>
 48  </path>
 49
 50  <target name="test-jar" depends="compile-test, jar">
 51    <delete file="${test.build.dir}/test-udfs.jar"/>
 52    <jar jarfile="${test.build.dir}/test-udfs.jar">
 53        <fileset dir="${test.build.classes}" includes="**/udf/*.class"/>
 54        <fileset dir="${test.build.classes}" includes="**/udf/generic/*.class"/>
 55    </jar>
 56  </target>
 57
 58  <target name="gen-test" depends="deploy-ant-tasks, test-conditions, test-init" >
 59    <taskdef name="qtestgen" classname="org.apache.hadoop.hive.ant.QTestGenTask"
 60             classpath="${build.dir.hive}/anttasks/hive-anttasks-${version}.jar:${hive.root}/lib/velocity-1.5.jar:${hive.root}/lib/commons-collections-3.2.1.jar:${hive.root}/lib/commons-lang-2.4.jar"/>
 61    
 62    <mkdir dir="${test.build.src}/org/apache/hadoop/hive/ql/parse"/>
 63    <mkdir dir="${test.build.src}/org/apache/hadoop/hive/cli"/>
 64    <mkdir dir="${test.log.dir}/contribpositive"/>
 65    <mkdir dir="${test.log.dir}/contribnegative"/>
 66    <mkdir dir="${test.log.dir}/contribclientpositive"/>
 67    <mkdir dir="${test.log.dir}/contribclientnegative"/>
 68
 69    <qtestgen outputDirectory="${test.build.src}/org/apache/hadoop/hive/ql/parse" 
 70              templatePath="${ql.test.template.dir}" template="TestParse.vm" 
 71              queryDirectory="${contrib.test.query.dir}/positive"
 72              queryFile="${qfile}"
 73              queryFileRegex="${qfile_regex}"
 74              runDisabled="${run_disabled}"
 75              resultsDirectory="${contrib.test.results.dir}/compiler" className="TestContribParse"
 76              logFile="${test.log.dir}/testcontribparsegen.log"
 77              logDirectory="${test.log.dir}/contribpositive"/>
 78    
 79 <!-- the TestContribParseNegative.java got removed? 
 80    <qtestgen outputDirectory="${test.build.src}/org/apache/hadoop/hive/ql/parse" 
 81              templatePath="${ql.test.template.dir}" template="TestParseNegative.vm" 
 82              queryDirectory="${contrib.test.query.dir}/negative" 
 83              queryFile="${qfile}"
 84              queryFileRegex="${qfile_regex}"
 85              runDisabled="${run_disabled}"
 86              resultsDirectory="${contrib.test.results.dir}/compiler/errors" className="TestContribParseNegative"
 87              logFile="${test.log.dir}/testcontribparseneggen.log"
 88              logDirectory="${test.log.dir}/contribnegative"/>
 89   -->
 90
 91    <qtestgen outputDirectory="${test.build.src}/org/apache/hadoop/hive/cli" 
 92              templatePath="${ql.test.template.dir}" template="TestCliDriver.vm" 
 93              queryDirectory="${contrib.test.query.dir}/clientpositive" 
 94              queryFile="${qfile}"
 95              queryFileRegex="${qfile_regex}"
 96              runDisabled="${run_disabled}"
 97              clusterMode="${clustermode}"
 98              resultsDirectory="${contrib.test.results.dir}/clientpositive" className="TestContribCliDriver"
 99              logFile="${test.log.dir}/testcontribclidrivergen.log"
100              logDirectory="${test.log.dir}/contribclientpositive"
101              hadoopVersion="${hadoopVersion}"
102    />
103
104    <qtestgen outputDirectory="${test.build.src}/org/apache/hadoop/hive/cli" 
105              templatePath="${ql.test.template.dir}" template="TestNegativeCliDriver.vm" 
106              queryDirectory="${contrib.test.query.dir}/clientnegative" 
107              queryFile="${qfile}"
108              queryFileRegex="${qfile_regex}"
109              runDisabled="${run_disabled}"
110              resultsDirectory="${contrib.test.results.dir}/clientnegative" className="TestContribNegativeCliDriver"
111              logFile="${test.log.dir}/testcontribnegclidrivergen.log"
112              logDirectory="${test.log.dir}/contribclientnegative"/>
113
114  </target>
115
116</project>