Uh oh!
There was an error while loading. Please reload this page.
sof-kernel-log-check: fix last_line / begin_line off-by-one error - #366
sof-kernel-log-check: fix last_line / begin_line off-by-one error#366marc-hb wants to merge 1 commit into
Conversation
If the last line of kern.log was an error then the _next_ test was failing. Found thanks to the new fake_kern_error() function submitted separately. Signed-off-by: Marc Herbert <marc.herbert@intel.com>
All the shellcheck warnings in https://travis-ci.org/github/thesofproject/sof-test/builds/725412899 were already there, this adds none. |
Interestingly, this makes a lot of tests fail in https://sof-ci.01.org/softestpr/PR366/build161/devicetest/. All of them seem to be because of: |
xiulipan
commented
Sep 9, 2020
@marc-hb I check the CI result. The logs are from very beginning this boot. It should be filter out by our last_line cmd. I think your PR here may have something wrong. |
| begin_line=${1:-1} | ||
| last_line=${1:-0} | ||
| begin_line=$((last_line+1)) |
There was a problem hiding this comment.
Please be aware the if input is 0, we will have fallback.
# confirm begin_line is number, if it is not the number, direct using dmesg
[[ "${begin_line//[0-9]/}" ]] && begin_line=0
[[ "$begin_line" -eq 0 ]] && cmd="dmesg" || cmd="sed -n '$begin_line,\$p' /var/log/kern.log"
marc-hb
commented
Dec 1, 2020
Made obsolete by #509 |
If the last line of kern.log was an error then the next test was failing.
Found thanks to the new fake_kern_error() function submitted separately.
Signed-off-by: Marc Herbert marc.herbert@intel.com