Fix Failed Tests summary missing assertion failures#111
Conversation
The FailedTestDetails list (shown in "Failed Tests:" summary and JSON output) only captured exception-based failures and promise rejections. Plain assertion failures like expect(1).toBe(2) set the test's failure flag but were never added to FailedTestDetails, making the summary line empty even when tests failed. Add assertion-failed tests to FailedTestDetails after EndTest, guarded by a FailureRecorded flag to avoid duplicating entries already added by exception/promise handlers. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Benchmark Results254 benchmarks Interpreted: 🟢 2 improved · 252 unchanged · avg +0.2% arraybuffer.js — Interp: 14 unch. · avg -1.3% · Bytecode: 14 unch. · avg +2.6%
arrays.js — Interp: 19 unch. · avg +0.0% · Bytecode: 19 unch. · avg +0.9%
async-await.js — Interp: 6 unch. · avg -0.5% · Bytecode: 6 unch. · avg +1.0%
classes.js — Interp: 31 unch. · avg +0.6% · Bytecode: 🟢 1, 30 unch. · avg +3.4%
closures.js — Interp: 11 unch. · avg -0.9% · Bytecode: 11 unch. · avg +2.2%
collections.js — Interp: 12 unch. · avg -0.6% · Bytecode: 12 unch. · avg +2.0%
destructuring.js — Interp: 22 unch. · avg +0.8% · Bytecode: 🟢 1, 21 unch. · avg +2.7%
fibonacci.js — Interp: 8 unch. · avg -2.4% · Bytecode: 8 unch. · avg +1.8%
for-of.js — Interp: 7 unch. · avg +0.5% · Bytecode: 🟢 1, 6 unch. · avg +3.4%
iterators.js — Interp: 20 unch. · avg -0.9% · Bytecode: 🟢 1, 19 unch. · avg +1.3%
json.js — Interp: 20 unch. · avg +0.3% · Bytecode: 🟢 3, 🔴 1, 16 unch. · avg +4.6%
jsx.jsx — Interp: 21 unch. · avg -1.1% · Bytecode: 🟢 4, 17 unch. · avg +4.5%
numbers.js — Interp: 11 unch. · avg -1.6% · Bytecode: 11 unch. · avg +2.1%
objects.js — Interp: 7 unch. · avg -1.2% · Bytecode: 🟢 1, 6 unch. · avg +3.5%
promises.js — Interp: 12 unch. · avg -0.1% · Bytecode: 🟢 7, 5 unch. · avg +8.2%
strings.js — Interp: 11 unch. · avg -0.3% · Bytecode: 🟢 5, 6 unch. · avg +6.3%
typed-arrays.js — Interp: 🟢 2, 20 unch. · avg +5.7% · Bytecode: 🟢 1, 21 unch. · avg +2.1%
Measured on ubuntu-latest x64. Changes within ±7% are considered insignificant. |
Suite Timing
Measured on ubuntu-latest x64. |
Summary
FailedTestDetailslist (shown inFailed Tests:summary line and JSON output) to include plain assertion failuresexpect(1).toBe(2)failures set the test's failure flag but were never added to the summaryFailureRecordedflag to avoid duplicating entries already added by exception/promise handlersBefore:
Failed Tests:line was empty even when tests failed via assertionsAfter:
Failed Tests: Test "this should fail",Test "addition" in suite "math"Test plan
Failed Tests:summary🤖 Generated with Claude Code