amplab/shark — pull request #115 by andyk (2013-08-07 05:26:11+00:00)
Title: New bin/run-tests-from-scratch to be used by Jenkins or new users as reference

Add a new bash script bin/run-tests-from-scratch that sets up a Shark environment (including the "master" branch of Spark) from scratch and runs the unit tests. The script requires JAVA_HOME and SCALA_HOME to be set but does all of the rest of the work for you, including:
1. Download and build Spark master
2. Download/untar/use whichever Hadoop is set to whatever by HADOOP_VERSION env var (or "0.20.205.0" is used if HADOOP_VERSION is unset)
3. Download patched Hive from github/amplab and build it
4. Run Hive tests with `ant test` until we see "[junit]" string and then kill those tests (kill all children tests too, which is a bit hairy)
5. Run Shark's `sbt/sbt test`
6. Run the Hive tests that Shark is known to pass via `TEST_FILE=src/test/tests_pass.txt ./bin/dev/test`

Flags can be passed to the tests to make life easier for developers by allowing them to skip portions of the setup that have completed successfully. Pass -h to see a list of available flags.

Once this is committed, Jenkins will use this script to run all of the tests every time a commit is made to master and I'll also set up a pull request builder that will run this script when asked to via github comments.