Merge lp:~psivaa/ubuntu-test-cases/touch-force-suite-timeout into lp:ubuntu-test-cases/touch

Proposed by Para Siva
Status: Merged
Approved by: Para Siva
Approved revision: 420
Merged at revision: 419
Proposed branch: lp:~psivaa/ubuntu-test-cases/touch-force-suite-timeout
Merge into: lp:ubuntu-test-cases/touch
Diff against target: 36 lines (+19/-2)
1 file modified
scripts/run-autopilot-tests.sh (+19/-2)
To merge this branch: bzr merge lp:~psivaa/ubuntu-test-cases/touch-force-suite-timeout
Reviewer Review Type Date Requested Status
Francis Ginther Approve
Review via email: mp+281248@code.launchpad.net

Commit message

use TEST_SUITE_TIMEOUT for being able to collect logs before job timeout.

Description of the change

To post a comment you must log in.
Revision history for this message
Francis Ginther (fginther) wrote :

Looks great!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'scripts/run-autopilot-tests.sh'
--- scripts/run-autopilot-tests.sh 2015-06-03 20:35:52 +0000
+++ scripts/run-autopilot-tests.sh 2015-12-22 19:20:37 +0000
@@ -93,13 +93,30 @@
93 # Use --timeout-profile=long only if we are using the emulator93 # Use --timeout-profile=long only if we are using the emulator
94 [ -z $USE_EMULATOR ] || EXTRA="-A '--timeout-profile=long'"94 [ -z $USE_EMULATOR ] || EXTRA="-A '--timeout-profile=long'"
9595
96 phablet-test-run \96 FORCE_TEST_SUITE_TIMEOUT=""
97 if [ -n "${TEST_SUITE_TIMEOUT}" ] ; then
98 # This is to help collect logs during cases where tests hang forever
99 # causing the job to timeout without collecting logs
100 # Forcing a timeout before the big-hammer job timeout will allow the
101 # consecutive log collection steps to complete.
102 FORCE_TEST_SUITE_TIMEOUT="timeout ${TEST_SUITE_TIMEOUT}"
103 fi
104 set +e
105 RET=0
106 ${FORCE_TEST_SUITE_TIMEOUT} phablet-test-run \
97 $NOSHELL $EXTRA \107 $NOSHELL $EXTRA \
98 -o ${odir} -f subunit \108 -o ${odir} -f subunit \
99 -a /var/crash -a /home/phablet/.cache/upstart \109 -a /var/crash -a /home/phablet/.cache/upstart \
100 -a /var/log/syslog \110 -a /var/log/syslog \
101 -A --timeout-profile=long \111 -A --timeout-profile=long \
102 -v $app || true112 -v $app
113 RET=$?
114 if [ "$RET" = "124" ];then
115 echo "========================================================"
116 echo "== Test suite $app timed out =="
117 echo "========================================================"
118 fi
119 set -e
103 adb shell rm -rf /tmp/ci-logs120 adb shell rm -rf /tmp/ci-logs
104 adb shell mkdir /tmp/ci-logs121 adb shell mkdir /tmp/ci-logs
105 adb shell sudo install -o phablet \122 adb shell sudo install -o phablet \

Subscribers

People subscribed via source and target branches