From afb00daa6aeea857b899cdfb0b059decbf5cc5d7 Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Wed, 4 Apr 2012 19:29:25 +0200 Subject: [PATCH] support different ports for different browsers --- schedule_selenium_tests.sh | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/schedule_selenium_tests.sh b/schedule_selenium_tests.sh index 9bf7ffe..a8add20 100755 --- a/schedule_selenium_tests.sh +++ b/schedule_selenium_tests.sh @@ -3,15 +3,23 @@ set -e export +TOKEN=$(pwgen) TEST_LANGUAGE=$(echo $JOB_NAME | cut -d "-" -f2) TEST_BROWSER=$(echo $JOB_NAME | cut -d "-" -f3) figlet $TEST_LANGUAGE figlet $TEST_BROWSER -TOKEN=$(pwgen) +if [ "$TEST_BROWSER" = "firefox" ] ; then + TEST_PORT=4444 +elif [ "$TEST_BROWSER" = "chrome" ] ; then + TEST_PORT=4445 +else + figlet "unknown browser" + exit 1 +fi -ssh -i ~jenkins/.ssh/id_selenium -t selenium@seoul ./runit.sh $TOKEN $TEST_LANGUAGE $TEST_BROWSER +ssh -i ~jenkins/.ssh/id_selenium -t selenium@seoul ./runit.sh $TOKEN $TEST_LANGUAGE $TEST_BROWSER $TEST_PORT scp -r -i ~jenkins/.ssh/id_selenium selenium@seoul:$TOKEN/* . ssh -i ~jenkins/.ssh/id_selenium selenium@seoul rm ./$TOKEN -Rf -- 2.39.5