mirror of
https://github.com/usebruno/bruno.git
synced 2026-06-11 09:51:30 +00:00
Playwright Codegen and CI setup
- Improved the Codegen setup - Removed the app-launch related boilerplate from tests - Enable recording mode by default - Option to provide the test file name to save the recording - Added GitHub workflow to run Playwright tests with Electron in Headless mode(mocking display using `xvfb`).
This commit is contained in:
@@ -1,17 +0,0 @@
|
||||
const path = require('path');
|
||||
const timer = require('node:timers/promises');
|
||||
const { _electron: electron } = require('playwright');
|
||||
|
||||
const electronAppPath = path.join(__dirname, '../packages/bruno-electron');
|
||||
|
||||
(async () => {
|
||||
const browser = await electron.launch({ args: [electronAppPath] });
|
||||
const context = await browser.context();
|
||||
await context.route('**/*', (route) => route.continue());
|
||||
|
||||
while (true) {
|
||||
if(browser.windows().length) break;
|
||||
await timer.setTimeout(200);
|
||||
}
|
||||
await browser.windows()[0].pause();
|
||||
})();
|
||||
Reference in New Issue
Block a user