Back to WorkflowBench
🛒MedusaTypeScript27.8k starsE-Commerce & Retail

Zero component tests for a production crash in a 27.8k-star e-commerce platform

Deleting a sales channel crashed the entire product list page. The two components responsible had exactly zero tests — not unit, not integration, not E2E.

8
Requirements Extracted
7
Verified Gaps
6%
Coverage Before
88%
Coverage After
Trace Matrix

Requirement-to-Test Traceability

Every requirement extracted from the PR, mapped to existing tests and verified against the codebase. Click any row to see the search evidence.

Coverage Distribution

8
7 Gaps
1 Partial
0 Covered

Requirement Coverage

Before6%
After OrangePro88%
+82% coverage improvement
8 requirements traced|7 gaps|1 partial|0 covered
R1GAP

UI must not crash when product links to deleted sales channel

SalesChannelsCell.tsx
R2GAP

Product details page handles null entries in sales_channels

ProductSalesChannelSection.tsx
R3GAP

Sales channel count tooltip shows correct number of valid channels

SalesChannelsCell.tsx
R4GAP

Tooltip list excludes entries for deleted channels

SalesChannelsCell.tsx
R5GAP

Product list renders correctly when some products have orphaned refs

SalesChannelsCell.tsx
R6PARTIAL

Deleting sales channel should remove associated product links

R7GAP

UI shows placeholder when product has no valid sales channels

SalesChannelsCell.tsx
R8GAP

System handles mix of valid and invalid sales channels

SalesChannelsCell.tsx
Critical Findings

Top 3 Verified Gaps

These gaps were verified by searching the repository's test directories. Each finding includes the exact search query and result so you can reproduce it yourself.

1

Zero component tests for data integrity issues

search evidence

Searched packages/**/__tests__ for 'SalesChannelsCell' and 'ProductSalesChannelSection' — found 0 results. The components responsible for rendering sales channel information lack any form of testing.

2

No end-to-end testing for sales channel lifecycle

search evidence

The bug originated from a data inconsistency created by deleting a sales channel. No E2E tests cover: create channel → associate with product → delete channel → verify product page still works.

3

No tests for edge cases in conditional rendering logic

search evidence

The code handles 0, 1, 2, or >2 sales channels differently (truncating, tooltips). No tests validate this conditional rendering, especially with null data mixed in.

Before vs. After

Coverage Comparison

RequirementBeforeAfter
UI crash on orphaned data✗ None✓ Unit + E2E
Graceful handling of nulls✗ None✓ Unit
Correct tooltip count✗ None✓ Unit
Accurate tooltip channel list✗ None✓ Unit
Product list view rendering✗ None✓ Unit + E2E
Backend cascade delete~ Partial✓ Integration
Placeholder for no channels✗ None✓ Unit
Mixed valid/invalid channels✗ None✓ Unit + E2E
Verifiable Evidence

Don't take our word for it. Verify it yourself.

Every finding in this analysis is based on a public GitHub repository. Clone the repo, run the searches we documented, and see the same results. No black boxes.