Skip to content

Commit 35732c9

Browse files
committed
Remove open shells as they get killed
1 parent b65ff10 commit 35732c9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/e2e-tests/test/test-shell.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -156,8 +156,10 @@ export class TestShell {
156156
}
157157

158158
static async killAll(): Promise<void> {
159+
// Using splice to mutate the array of open shells in-place
160+
const openShells = TestShell._openShells.splice(0);
159161
await Promise.all(
160-
TestShell._openShells.map((shell) => {
162+
openShells.map((shell) => {
161163
shell.kill();
162164
return shell.waitForExit();
163165
})

0 commit comments

Comments
 (0)