-
Notifications
You must be signed in to change notification settings - Fork 5
Submitting and Testing Pull Requests
Ideally, running bootstrap.sh from dev-tools master should always succeed against aeolusproject/conductor master. Since dev-tools does not have unit tests or an automated build system behind it, we rely heavily on human testing for now. So, whenever a user submits pull request, he or she should test it in a very specific way as a sudo-enabled non-root user. Specifically, immediately after submitting the pull request the submitter should follow this pattern very closely (the three "export" variables may differ a bit if the user chooses)-- setting DEV_TOOLS_PULL_REQUEST to the appropriate integer.
DEV_TOOLS_PULL_REQUEST=37
export FACTER_CONDUCTOR_PORT=3033
export WORKDIR=/home/$USER/pull-request-$DEV_TOOLS_PULL_REQUEST
export RBENV_VERSION=1.9.3-p374
rm -rf $WORKDIR
mkdir $WORKDIR
cd $WORKDIR
git clone https://github.com/aeolus-incubator/dev-tools.git
cd dev-tools
curl https://github.com/aeolus-incubator/dev-tools/pull/$DEV_TOOLS_PULL_REQUEST.patch | patch -p1
git diff | cat
echo '======================================================'
echo You are about to test the above patch.
echo Does this look like what you are expecting?
echo '======================================================'
echo Press Control-C to quit, or ENTER to continue
read waiting
/bin/bash -x bootstrap.sh 2>&1 | tee -a /tmp/dev-tools-pull-request-$DEV_TOOLS_PULL_REQUEST.out
For convenience, the above may be downloaded from https://gist.github.com/4679159. It is user-discretion to decide how many OS'es to test given the patch, but the OS'es tested should be mentioned as a comment in the pull request.
Since conductor master is a moving target, sometimes conductor is responsible for breaking dev-tools. The best way to verify that is to try an older version of conductor, specifying a git commit hash before running bootstrap.sh, e.g.:
export FACTER_CONDUCTOR_BRANCH=<commit hash here>