Skip to content

Commit

Permalink
HADOOP-11950. Add cli option to test-patch to set the project-under-t…
Browse files Browse the repository at this point in the history
…est (Sean Busbey via aw)
  • Loading branch information
aw-was-here committed May 11, 2015
1 parent baeb479 commit 2d671e5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
13 changes: 11 additions & 2 deletions dev-support/test-patch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ function setup_defaults
PROJECT_NAME=hadoop
HOW_TO_CONTRIBUTE="https://wiki.apache.org/hadoop/HowToContribute"
JENKINS=false
PATCH_DIR=/tmp/${PROJECT_NAME}-test-patch/$$
BASEDIR=$(pwd)

FINDBUGS_HOME=${FINDBUGS_HOME:-}
Expand Down Expand Up @@ -585,6 +584,7 @@ function hadoop_usage
echo "--modulelist=<list> Specify additional modules to test (comma delimited)"
echo "--offline Avoid connecting to the Internet"
echo "--patch-dir=<dir> The directory for working and output files (default '/tmp/${PROJECT_NAME}-test-patch/pid')"
echo "--project=<name> The short name for project currently using test-patch (default 'hadoop')"
echo "--resetrepo Forcibly clean the repo"
echo "--run-tests Run all relevant tests below the base directory"
echo "--testlist=<list> Specify which subsystem tests to use (comma delimited)"
Expand Down Expand Up @@ -695,7 +695,10 @@ function parse_args
PATCH=${i#*=}
;;
--patch-dir=*)
PATCH_DIR=${i#*=}
USER_PATCH_DIR=${i#*=}
;;
--project=*)
PROJECT_NAME=${i#*=}
;;
--ps-cmd=*)
PS=${i#*=}
Expand Down Expand Up @@ -755,6 +758,12 @@ function parse_args
JENKINS=false
fi

if [[ -n ${USER_PATCH_DIR} ]]; then
PATCH_DIR="${USER_PATCH_DIR}"
else
PATCH_DIR=/tmp/${PROJECT_NAME}-test-patch/$$
fi

cd "${CWD}"
if [[ ! -d ${PATCH_DIR} ]]; then
mkdir -p "${PATCH_DIR}"
Expand Down
3 changes: 3 additions & 0 deletions hadoop-common-project/hadoop-common/CHANGES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -554,6 +554,9 @@ Release 2.8.0 - UNRELEASED
HADOOP-11906. test-patch.sh should use 'file' command for patch
determinism (Sean Busbey via aw)

HADOOP-11950. Add cli option to test-patch to set the project-under-test
(Sean Busbey via aw)

OPTIMIZATIONS

HADOOP-11785. Reduce the number of listStatus operation in distcp
Expand Down

0 comments on commit 2d671e5

Please sign in to comment.