From bd0665302223be1f774573ca27d5a8eb95618293 Mon Sep 17 00:00:00 2001 From: 0xPatrick Date: Wed, 24 Jan 2024 22:23:32 -0500 Subject: [PATCH] fixup! test: add ui test with puppeteer --- ui/package.json | 1 - ui/test/App.e2e.ts | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/ui/package.json b/ui/package.json index 9223637..51631fe 100644 --- a/ui/package.json +++ b/ui/package.json @@ -34,7 +34,6 @@ "eslint-plugin-prettier": "^5.1.3", "eslint-plugin-react-hooks": "^4.6.0", "eslint-plugin-react-refresh": "^0.4.3", - "execa": "^8.0.1", "happy-dom": "^13.3.1", "prettier": "^3.2.4", "puppeteer": "^21.9.0", diff --git a/ui/test/App.e2e.ts b/ui/test/App.e2e.ts index deb90fa..5e7ca1c 100644 --- a/ui/test/App.e2e.ts +++ b/ui/test/App.e2e.ts @@ -1,10 +1,10 @@ import puppeteer from 'puppeteer'; -import { execa } from 'execa'; +import { execSync, spawn } from 'node:child_process'; describe('Puppeteer E2E test', () => { it('should load the webpage', async () => { - await execa('yarn', ['build']); - const previewServer = execa('yarn', ['preview'], { + execSync('yarn build'); + const previewServer = spawn('yarn', ['preview'], { detached: true, stdio: 'ignore', });