32 lines
1.2 KiB
Bash
32 lines
1.2 KiB
Bash
#!/bin/bash
|
|
if [ -f /var/www/html/api/playwright-v94-selenium-authed.json ]; then
|
|
stat -c "file ts: %y" /var/www/html/api/playwright-v94-selenium-authed.json
|
|
cat /var/www/html/api/playwright-v94-selenium-authed.json | python3 -c "
|
|
import json, sys
|
|
d = json.load(sys.stdin)
|
|
for p in d:
|
|
print(f'=== {p.get(\"page\")} ===')
|
|
if 'err' in p:
|
|
print(f' ERR: {p[\"err\"]}')
|
|
continue
|
|
diag = p.get('diag', {})
|
|
print(f' url: {diag.get(\"url\",\"\")[:70]}')
|
|
print(f' is_login: {diag.get(\"is_login\")}')
|
|
print(f' body_len: {diag.get(\"body_len\")}')
|
|
print(f' canvas/svg: {diag.get(\"canvas_count\")}/{diag.get(\"svg_count\")}')
|
|
print(f' AG: {diag.get(\"AG_length\",0)} (dead={diag.get(\"AG_dead\",0)} noact={diag.get(\"AG_no_actions\",0)} anon={diag.get(\"AG_anonymous\",0)})')
|
|
print(f' DP: {diag.get(\"DP_length\",0)}')
|
|
arrays = diag.get('data_arrays', {})
|
|
if arrays:
|
|
big = sorted(arrays.items(), key=lambda x: -x[1])[:5]
|
|
print(f' data_arrays: {big}')
|
|
if p.get('errs'):
|
|
print(f' errs[{len(p[\"errs\"])}]: {p[\"errs\"][:2]}')
|
|
print()
|
|
"
|
|
else
|
|
echo "Test not finished or failed"
|
|
ls -la /tmp/v94-videos/ 2>/dev/null | head -5
|
|
ls -la /tmp/v94-*.png 2>/dev/null
|
|
fi
|