...
Code Block |
---|
mvn clean install -DskipTests -Phadoop-1 cd itests mvn clean install -DskipTests -Phadoop-1 |
How do I import into eclipse?
...
Code Block |
---|
$ mkdir workspace $ cd workspace $ git clone https://github.com/apache/hive.git $ cd hive $ mvn clean install -DskipTests -Phadoop-1 $ mvn eclipse:clean $ mvn eclipse:eclipse -DdownloadSources -DdownloadJavadocs -Phadoop-1 $ cd itests $ mvn clean install -DskipTests -Phadoop-1 $ mvn eclipse:clean $ mvn eclipse:eclipse -DdownloadSources -DdownloadJavadocs -Phadoop-1 |
In eclipse define M2_REPO in Preferences -> Java -> Build Path -> Classpath Variables to either:
...
Code Block |
---|
mvn clean package -DskipTests -Phadoop-1 -Pdist
|
It will then be located in packaging/target/
...
Code Block |
---|
cd odbc mvn compile -Phadoop-Podbc1,odbc -Dthrift.home=/usr/local -Dboost.home=/usr/local |
...
Code Block |
---|
mvn clean install -DskipTests -Phadoop-1 cd itests mvn clean install -DskipTests -Phadoop-1 |
Testing
How do I run a single test?
...
No Format |
---|
mvn test -Dtest=ClassName -Phadoop-1
|
Single test method:
No Format |
---|
mvn test -Dtest=ClassName#methodName -Phadoop-1
|
How do I debug into a single test in Eclipse?
...
If any test fails with the error below it means you have an inappoprate inappropriate umask setting. It should be set to 0022.
...
Code Block |
---|
ant clean package test |
MVN:
Code Block |
---|
mvn test -Phadoop-1 cd itests mvn test -Phadoop-1 |
Note that running ant test
will not work; ant package
does some setup work that is required for the testcases to run successfully.
...
Code Block |
---|
mvn clean install -DskipTests -Phadoop-1 cd itests mvn clean install -DskipTests -Phadoop-1 |
How do update the output of a CliDriver testcase?
...
Code Block |
---|
cd itests/qtest
mvn test -Dtest=TestCliDriver -Dqfile=alter1.q -Dtest.output.overwrite=true -Phadoop-1
|
As of Hive 0.11.0+ you can cut this time in half by specifying that only the ql module needs to rebuild
...
Code Block |
---|
cd itests/qtest
mvn test -Dtest=TestCliDriver -Phadoop-1
|
To run a single clientnegative test alter1.q
...
Code Block |
---|
cd itests/qtest
mvn test -Dtest=TestNegativeCliDriver -Dqfile=alter1.q -Phadoop-1
|
To run all of the clientpositive tests that match a regex, e.g. the partition_wise_fileformat tests
...
Code Block |
---|
cd itests/qtest
mvn test -Dtest=TestCliDriver -Dqfile_regex=partition_wise_fileformat.* -Phadoop-1
|
To run a single contrib test alter1.q and overwrite the result file
...
Code Block |
---|
cd itests/qtest
mvn test -Dtest=TestContribCliDriver -Dqfile=alter1.q -Dtest.output.overwrite=true -Phadoop-1
|
To run a single test groupby1.q and output detailed information during execution
...