Commit bdc9c9c
test(teams): stop the add-team click from landing in a toast (#31734)
* test(teams): stop the add-team click from landing in a toast
addTeamHierarchy clicked the add button with `force: true`, which skips the
hit-target check. The backend fans delete/job notifications out to every
socket of the logged-in admin, so a parallel worker's success toast can sit
over that button — and with force the click was dispatched into the toast.
The click "succeeded", the modal never opened, and the failure surfaced 15s
later on the modal assertion.
Success toasts carry no close button and self-dismiss after 3.5s, so
clicking without force is the fix: the hit-target check waits the toast out.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* test(teams): retry the add-team open when a toast eats the click
Dropping `force` was not enough. Playwright checks the hit target and then
dispatches, so a socket-fanned success toast landing in that window still
swallows the click — the trace shows the click "succeeding" in 16ms with a
delete toast on screen and the modal never opening.
Route every add-team trigger through openAddTeamModal: let a pending toast
expire, click, and retry until the modal is up.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
(cherry picked from commit af609a6)1 parent 6db2ba9 commit bdc9c9c
2 files changed
Lines changed: 49 additions & 16 deletions
Lines changed: 3 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
58 | 58 | | |
59 | 59 | | |
60 | 60 | | |
| 61 | + | |
61 | 62 | | |
62 | 63 | | |
63 | 64 | | |
| |||
192 | 193 | | |
193 | 194 | | |
194 | 195 | | |
195 | | - | |
196 | | - | |
197 | | - | |
| 196 | + | |
198 | 197 | | |
199 | 198 | | |
200 | 199 | | |
| |||
427 | 426 | | |
428 | 427 | | |
429 | 428 | | |
430 | | - | |
431 | | - | |
432 | | - | |
| 429 | + | |
433 | 430 | | |
434 | 431 | | |
435 | 432 | | |
| |||
Lines changed: 46 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
36 | 77 | | |
37 | 78 | | |
38 | 79 | | |
| |||
252 | 293 | | |
253 | 294 | | |
254 | 295 | | |
255 | | - | |
256 | | - | |
257 | | - | |
258 | | - | |
259 | | - | |
260 | | - | |
261 | | - | |
262 | | - | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
263 | 300 | | |
264 | | - | |
265 | 301 | | |
266 | 302 | | |
267 | 303 | | |
| |||
621 | 657 | | |
622 | 658 | | |
623 | 659 | | |
624 | | - | |
| 660 | + | |
625 | 661 | | |
626 | 662 | | |
627 | 663 | | |
| |||
0 commit comments