| Message ID | 20261206061045.7-4-bbnpreetsingh@gmail.com |
|---|---|
| State | Under Review |
| Headers | show |
| Series | ptest-pgxs.bbclass: three more fixes | expand |
diff --git a/meta-oe/classes/ptest-pgxs.bbclass b/meta-oe/classes/ptest-pgxs.bbclass index 70d9b80a87..a5013111bc 100644 --- a/meta-oe/classes/ptest-pgxs.bbclass +++ b/meta-oe/classes/ptest-pgxs.bbclass @@ -106,7 +106,8 @@ LOG="$WORK/pg_regress.log" tee "$LOG" | sed -n -e 's/^ok [0-9]* *[-+] *\([^ ]*\).*/PASS: \1/p' \ -e 's/^not ok [0-9]* *[-+] *\([^ ]*\).*/FAIL: \1/p' -RC=$(cat "$WORK/rc" 2>/dev/null || echo 2) +RC=$(cat "$WORK/rc" 2>/dev/null) +[ -n "$RC" ] || RC=2 if [ "$RC" -ne 0 ]; then if [ "$RC" -ne 1 ] || ! grep -q '^\(not \)\{0,1\}ok [0-9]' "$LOG"; then
When the tests fill /tmp, the file holding the exit status is left empty and run-ptest stops with "sh: bad number", without a FAIL line or the log. Signed-off-by: Babanpreet Singh <bbnpreetsingh@gmail.com> --- meta-oe/classes/ptest-pgxs.bbclass | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)