From f5d2a5ceb4030aa0868b11ef84b5055b70693702 Mon Sep 17 00:00:00 2001 From: Sean Dague Date: Thu, 6 Mar 2014 13:45:42 -0500 Subject: [PATCH] test for adding crazy branches as found by dansmith's clever hack, if devstack lands a crazy branch name in stackrc, we'd break the devstack gate. While it's doubtful anyone would do this, add a basic sanity check. Change-Id: Ib3b1881ed4fd520a1828ed073a7c8353e6f0a839 --- run_tests.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/run_tests.sh b/run_tests.sh index a0bfbee0c0..685b2037f0 100755 --- a/run_tests.sh +++ b/run_tests.sh @@ -27,3 +27,16 @@ fi echo "Running bash8..." ./tools/bash8.py -v $FILES + + +# Test that no one is trying to land crazy refs as branches + +echo "Ensuring we don't have crazy refs" + +REFS=`grep BRANCH stackrc | grep -v -- '-master'` +rc=$? +if [[ $rc -eq 0 ]]; then + echo "Branch defaults must be master. Found:" + echo $REFS + exit 1 +fi