tox_env.sh
author Justin Wood <Callek@gmail.com>
Tue, 06 Jan 2015 11:02:19 +0100
changeset 11599 a599d98c55de09bf0b902d8c588b0e0fd668984d
parent 11598 222b655abc77b015f2e4f1ba450c1e75f976cf0b
child 11857 05c0f42e3e6770655fb9ec7b4c5bd79fdad64042
permissions -rwxr-xr-x
Bug 1076810 - RelEng CI tests should be available over the internet, not just from VPN - allow pep8 failures not to break tests and remove coveralls from README.md,r=pmoore

#!/bin/bash -e
[ -z "${1}" ] || [ -z "${2}" ] && exit 1
TOX_INI_DIR="${1}"
TOX_WORK_DIR="${2}"

function hgme {
    repo="${1}"
    if [ ! -d "${TOX_WORK_DIR}/${repo}" ]; then
        hg clone https://hg.mozilla.org/build/${repo} "${TOX_WORK_DIR}/${repo}"
    else
        # this is equivalent to hg purge but doesn't require the hg purge plugin to be enabled
        hg status -un0 -R "${TOX_WORK_DIR}/${repo}" | xargs rm -rf
        hg pull -u -R "${TOX_WORK_DIR}/${repo}"
    fi
}

hgme tools
hgme buildbotcustom
hgme buildbot

hg -R "${TOX_WORK_DIR}/buildbot" checkout production-0.8
cd "${TOX_WORK_DIR}/buildbot/master" && python setup.py install
rm -rf "${TOX_INI_DIR}/test-output"
rm -rf "${TOX_INI_DIR}/run/shm/buildbot"
mkdir -p "${TOX_INI_DIR}/run/shm/buildbot"