forked from molecule-ai/molecule-core
Cherry-picked from PR #452 (fix/canvas-test-and-design-fixes) which was closed without merge during the PR #443 cascade. The fix adds a mockPost reference so individual tests can reset the POST mock cleanly instead of queueing multiple resolved/rejected values. Without this, the "shows an error toast when POST fails" and "keeps the card visible when POST fails" tests queue two responses from beforeEach's mockResolvedValue({}) and the second mockRejectedValueOnce() call, causing non-deterministic test outcomes. Fixes test failures in ApprovalBanner suite. |
||
|---|---|---|
| .. | ||
| __tests__ | ||
| app | ||
| components | ||
| hooks | ||
| lib | ||
| store | ||
| stores | ||
| styles | ||
| types | ||
| middleware.ts | ||