codeceptjs / codeceptjs/CodeceptJS

Puppeteer: using restart: false during tests will let browser stuck

オープン
#2,950 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る
bug puppeteer
主要言語
JavaScript
スター
4.2k
フォーク
757
平均マージ
2日 9時間
マージ済み PR(30日)
16

説明

Hi.
I'm trying to use persistent browser state with Puppeteer so multiple scenarios can be run without browser restarts between them. Since all other tests are arranged with the default restart config, I'm trying to use the dynamic `.config('restart: false')` in one single suite, like so:
```
Feature('My grouped tests in one feature').config({ restart: false });
// hooks and scenarios
```

Tests themselves behave exactly as intended. The problem is, after the last test finishes and passes, the browser will remain open, stuck, preventing the test queue to continue.

Since I'm running tests on a pipeline, this is preventing me to use this feature.

I noticed this have been reported before for WebDriverIO.

Is there any workaround for this?

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

まず、Puppeteer helper による動的な .config({ restart: false }) 設定の処理と、feature 完了後のブラウザーのライフサイクルを確認します。restart を無効にした状態でグループ化された feature を再現し、その後、デフォルトの restart 設定と比較して、最後のシナリオの後も test queue が継続することを検証します。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
javascript
領域
testing-qa
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。