docs: the README e2e limits list omits the harness accommodation that neutralizes window.close #293
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
README.md, End-to-End Tests section, lists the standing limits of the dApp coverage. It does not mention the one accommodation the harness makes to the shipped code.tests/e2e/run.js:1599-1624—reserveApprovalTab()injectswindow.close = function () {}into the site-connection approval page. The harness comment states the reason: in a tab, thewindow.close()on the line afterruntime.sendMessage()races the approve message and the teardown wins. The comment also records that whether the same ordering holds in a real toolbar popup is not observable from a headless harness.That is a genuine limit of what the browser suites prove, and the limits list is the section a reader consults to learn exactly that. Found while removing a stale limit from the same list in #285, and deliberately left out of scope there because that unit was docs-only by design.
Sequencing — do not start this before #275 lands
The accommodation exists because of the race that #275 fixes, currently in flight as #289. Depending on how that lands, the correct fix here is one of two things, and which one is not yet knowable:
Resolve #275 first, then take whichever branch applies.
Definition of done
README.mdmatches every accommodationtests/e2e/run.jsactually makes to the shipped code — no accommodation undocumented, no documented limit that is no longer real.window.closeinjection is either gone or described.TODO.mdupdated in the same commit.make checkpasses.