From 92144184b4c5cf43f18e6bb74ff4f1192739e13a Mon Sep 17 00:00:00 2001 From: David Mendez Date: Mon, 20 Oct 2014 14:53:57 +0200 Subject: [PATCH] PR Tests: added a script that queues the new prs to be tested. --- queue-new-prs | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 queue-new-prs diff --git a/queue-new-prs b/queue-new-prs new file mode 100755 index 0000000000000..8894063b418e4 --- /dev/null +++ b/queue-new-prs @@ -0,0 +1,17 @@ +#!/bin/sh -ex + +# Uses query-new-pull-requests to get the latest PRS. +# It checks if the PR is for a branch for which automatic tests are activated. +# Finally, it creates a properties file with the PR number for jenkins to trigger the next job. + +for PR in `./query-new-pull-requests ${TIME_INTERVAL}`; do + + # Use helper to get PR branch + RELEASE_QUEUE=`./get-pr-branch $PR` + if cat config.map | grep $RELEASE_QUEUE | grep -v DISABLED= | grep PR_TESTS= ; then + echo 'Creating properties file for '$PR + echo "PULL_REQUEST=$PR" >> $WORKSPACE/approve-pr-tests-$PR-properties.txt + fi + + +done