Merge lp:~bladernr/checkbox/1095713-set-pipefail-on-sleep-jobs into lp:checkbox

Proposed by Jeff Lane 
Status: Merged
Approved by: Zygmunt Krynicki
Approved revision: 1863
Merged at revision: 1863
Proposed branch: lp:~bladernr/checkbox/1095713-set-pipefail-on-sleep-jobs
Merge into: lp:checkbox
Diff against target: 60 lines (+9/-6)
3 files modified
debian/changelog (+3/-0)
jobs/stress.txt.in (+4/-4)
jobs/suspend.txt.in (+2/-2)
To merge this branch: bzr merge lp:~bladernr/checkbox/1095713-set-pipefail-on-sleep-jobs
Reviewer Review Type Date Requested Status
Zygmunt Krynicki (community) Approve
Review via email: mp+141792@code.launchpad.net

Description of the change

While looking into the sleep test results Ara noticed that results that indicated a failure were being passed. This was due to the command and checkbox picking up the exit code for tee rather than sleep_test or fwts_test. This is fixed by adding 'set -o pipefail' where appropriate to ensure that the test exit code is what checkbox picks up.

To post a comment you must log in.
Revision history for this message
Zygmunt Krynicki (zyga) wrote :

+1, makes sense

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2013-01-02 13:13:29 +0000
3+++ debian/changelog 2013-01-03 17:28:23 +0000
4@@ -37,6 +37,9 @@
5 unity_support_test. They should pipe through ansi_parser like other jobs.
6 (LP: #1087777)
7 * jobs/info.txt.in - added job info/disk_partitions (LP: #1081833)
8+ * jobs/stress.txt.in, jobs/suspend.txt.in - fixed a bug in the command for
9+ the suspend jobs where checkbox was getting the exitcode for tee rather
10+ than for sleep_test or fwts_test (LP: #1095713)
11
12 [Sylvain Pineau]
13 * jobs/info.txt.in: Fixed the requirement of info/touchpad_driver.
14
15=== modified file 'jobs/stress.txt.in'
16--- jobs/stress.txt.in 2012-11-08 15:37:30 +0000
17+++ jobs/stress.txt.in 2013-01-03 17:28:23 +0000
18@@ -39,10 +39,10 @@
19 command:
20 if type -P fwts >/dev/null; then
21 echo "Calling fwts"
22- fwts_test -l $CHECKBOX_DATA/suspend_30_cycles -s s3 --s3-device-check --s3-device-check-delay=30 --s3-sleep-delay=30 --s3-multiple=30 | tee $CHECKBOX_DATA/suspend_30_cycles_times.log
23+ set -o pipefail; fwts_test -l $CHECKBOX_DATA/suspend_30_cycles -s s3 --s3-device-check --s3-device-check-delay=30 --s3-sleep-delay=30 --s3-multiple=30 | tee $CHECKBOX_DATA/suspend_30_cycles_times.log
24 else
25 echo "Calling sleep_test"
26- sleep_test -p s mem -i 30 | tee $CHECKBOX_DATA/suspend_30_cycles_times.log
27+ set -o pipefail; sleep_test -p s mem -i 30 | tee $CHECKBOX_DATA/suspend_30_cycles_times.log
28 fi
29 _description:
30 PURPOSE:
31@@ -91,10 +91,10 @@
32 command:
33 if type -P fwts >/dev/null; then
34 echo "Calling fwts"
35- fwts_test -l $CHECKBOX_DATA/suspend_250_cycles -s s3 --s3-device-check --s3-device-check-delay=30 --s3-sleep-delay=30 --s3-multiple=250 | tee $CHECKBOX_DATA/suspend_250_cycles_times.log
36+ set -o pipefail; fwts_test -l $CHECKBOX_DATA/suspend_250_cycles -s s3 --s3-device-check --s3-device-check-delay=30 --s3-sleep-delay=30 --s3-multiple=250 | tee $CHECKBOX_DATA/suspend_250_cycles_times.log
37 else
38 echo "Calling sleep_test"
39- sleep_test -p s mem -i 250 | tee $CHECKBOX_DATA/suspend_250_cycles_times.log
40+ set -o pipefail; sleep_test -p s mem -i 250 | tee $CHECKBOX_DATA/suspend_250_cycles_times.log
41 fi
42 _description:
43 PURPOSE:
44
45=== modified file 'jobs/suspend.txt.in'
46--- jobs/suspend.txt.in 2012-12-12 09:48:07 +0000
47+++ jobs/suspend.txt.in 2013-01-03 17:28:23 +0000
48@@ -98,10 +98,10 @@
49 command:
50 if type -P fwts >/dev/null; then
51 echo "Calling fwts"
52- fwts_test -l $CHECKBOX_DATA/suspend_single -s s3 --s3-sleep-delay=30 --s3-device-check | tee $CHECKBOX_DATA/suspend_single_times.log
53+ set -o pipefail; fwts_test -l $CHECKBOX_DATA/suspend_single -s s3 --s3-sleep-delay=30 --s3-device-check | tee $CHECKBOX_DATA/suspend_single_times.log
54 else
55 echo "Calling sleep_test"
56- sleep_test -p | tee $CHECKBOX_DATA/suspend_single_times.log
57+ set -o pipefail; sleep_test -p | tee $CHECKBOX_DATA/suspend_single_times.log
58 fi
59 _description:
60 PURPOSE:

Subscribers

People subscribed via source and target branches