summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xbin/test_torbrowser-launcher.sh13
1 files changed, 10 insertions, 3 deletions
diff --git a/bin/test_torbrowser-launcher.sh b/bin/test_torbrowser-launcher.sh
index e4836129..4b4fc226 100755
--- a/bin/test_torbrowser-launcher.sh
+++ b/bin/test_torbrowser-launcher.sh
@@ -239,11 +239,18 @@ download_and_launch() {
update_screenshot
sleep 0.5
xvkbd -text "\r" > /dev/null 2>&1
- for i in $(seq 1 2) ; do
- sleep 15
+ BONUS_LEVEL=""
+ for i in $(seq 1 6) ; do
+ sleep 5
+ URL_LOADED=$(gocr $WORKSPACE/screenshot.png 2>/dev/null | grep -c "Debian" || true)
update_screenshot
+ if [ $URL_LOADED -ge 6 ] ; then
+ echo "$(date -u) - $URL loaded fine, very much Debian in there, great."
+ BONUS_LEVEL=" Well done."
+ break
+ fi
done
- echo "'$(date -u) - torbrowser tests end.'" | tee | xargs schroot --run-session -c $SESSION --preserve-environment -- notify-send
+ echo "'$(date -u) - torbrowser tests end.$BONUS_LEVEL'" | tee | xargs schroot --run-session -c $SESSION --preserve-environment -- notify-send
update_screenshot
echo "$(date) - telling awesome to quit."
echo 'awesome.quit()' | schroot --run-session -c $SESSION --preserve-environment -- awesome-client