Merge pull request #690 from psychon/make-test-runner-more-robust
Make the functional test runner more robust
This commit is contained in:
commit
9257c96b7c
|
@ -79,6 +79,9 @@ runner.run_steps = function(steps)
|
||||||
for _,c in ipairs(client.get()) do
|
for _,c in ipairs(client.get()) do
|
||||||
c:kill()
|
c:kill()
|
||||||
end
|
end
|
||||||
|
if success and result then
|
||||||
|
io.stderr:write("Test finished successfully\n")
|
||||||
|
end
|
||||||
awesome.quit()
|
awesome.quit()
|
||||||
end) end)
|
end) end)
|
||||||
t:start()
|
t:start()
|
||||||
|
|
|
@ -169,9 +169,10 @@ for f in $tests; do
|
||||||
# Tail the log and quit, when awesome quits.
|
# Tail the log and quit, when awesome quits.
|
||||||
tail -n 100000 -f --pid $awesome_pid $awesome_log
|
tail -n 100000 -f --pid $awesome_pid $awesome_log
|
||||||
|
|
||||||
if grep -q -E '^Error|assertion failed' $awesome_log; then
|
if ! grep -q -E '^Test finished successfully$' $awesome_log ||
|
||||||
|
grep -q -E '[Ee]rror|assertion failed' $awesome_log; then
|
||||||
echo "===> ERROR running $f! <==="
|
echo "===> ERROR running $f! <==="
|
||||||
grep --color -o --binary-files=text -E '^Error.*|.*assertion failed.*' $awesome_log
|
grep --color -o --binary-files=text -E '.*[Ee]rror.*|.*assertion failed.*' $awesome_log
|
||||||
errors=$(expr $errors + 1)
|
errors=$(expr $errors + 1)
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
Loading…
Reference in New Issue