Skip to content

How to test playwright

Cesar Celis Hernandez edited this page Mar 8, 2023 · 16 revisions
  1. MinIO:
MINIO_ROOT_USER=minioadmin MINIO_ROOT_PASSWORD=minioadmin minio server /Volumes/data{1...4} --address :9000 --console-address :9001
  1. console server at 9090
cd ~/console
make install
~/go/bin/console server
  1. console at port 5005
cd ~/console/portal-ui
yarn install
yarn build
yarn run start
  1. Execute the tests:
cd /Users/cniackz/console/portal-ui
npx playwright test

You should see:

$ npx playwright test

Running 6 tests using 5 workers
  6 passed (5.2s)

To open last HTML report run:

  npx playwright show-report
  1. get report
npx playwright show-report
Screenshot 2023-03-08 at 1 18 23 PM
  1. get coverage
yarn add -D nyc
yarn global add nyc
npm install -g nyc
nyc report --reporter=html
URL: file:///Users/cniackz/console/portal-ui/coverage/index.html
Clone this wiki locally