Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install Playwright (cypress dead) #6598

Closed
roiLeo opened this issue Aug 7, 2023 · 16 comments · Fixed by #6920
Closed

Install Playwright (cypress dead) #6598

roiLeo opened this issue Aug 7, 2023 · 16 comments · Fixed by #6920
Assignees
Labels
$$ ~51-150usd 🙄 - found some 🐛 and something WFM A-tests error-tracking p2 core functionality, or is affecting 60% of app

Comments

@roiLeo
Copy link
Contributor

roiLeo commented Aug 7, 2023

On latest PR cypress tests are failing

Process returned exit code 1
Launched as "pnpm start:static & pnpm wait-on http://localhost:9090 && MATRIX=4 node tests/cypress/e2e-run-tests.js"
Launched at "/__w/nft-gallery/nft-gallery"
Attempts exhausted, made 3 attempts :
Attempt #1 started at : 08:04:47 GMT+0000 (Coordinated Universal Time)
Attempt #2 started at : 08:05:18 GMT+0000 (Coordinated Universal Time)
Attempt #3 started at : 08:05:32 GMT+0000 (Coordinated Universal Time)

Task

ref

@vikiival
Copy link
Member

vikiival commented Aug 7, 2023

cc @preschian

@vikiival
Copy link
Member

vikiival commented Aug 7, 2023

migrate to playwrigth?

Yup I think it would be much faster

@yangwao
Copy link
Member

yangwao commented Aug 7, 2023

yes, we've been researching this one last summer irc

@yangwao yangwao changed the title cypress dead Install Playwright (cypress dead) Aug 7, 2023
@yangwao yangwao added $$ ~51-150usd p2 core functionality, or is affecting 60% of app labels Aug 7, 2023
@yangwao
Copy link
Member

yangwao commented Aug 7, 2023

@prury this is an ideal opportunity to learn new thing! :)

@preschian
Copy link
Member

cc @preschian

migrate to playwrigth?

Yup I think it would be much faster

yes, we've been researching this one last summer irc

yes, I agree with this. since @vikiival already research that a long time ago

@preschian
Copy link
Member

I just found out that we removed cypress once before #3052
and then add cypress back #3451

@yangwao
Copy link
Member

yangwao commented Aug 7, 2023

now we can learn from that mistake, remove it and add playwright 😄

If I get it right, some tests could be recycled?

@prury
Copy link
Member

prury commented Aug 7, 2023

@prury this is an ideal opportunity to learn new thing! :)

oh, definitely, good thing i learned just the basics about cypress and do not went too further
playwright it is then

@prury
Copy link
Member

prury commented Aug 9, 2023

👋

@kodabot
Copy link
Collaborator

kodabot commented Aug 9, 2023

ASSIGNED - @prury 🔒 LOCKED -> Friday, August 11th 2023, 15:25:29 UTC -> 48 hours

@prury prury mentioned this issue Aug 9, 2023
3 tasks
@kodabot
Copy link
Collaborator

kodabot commented Aug 11, 2023

ASSIGNMENT EXPIRED - @prury has been unassigned.

@prury
Copy link
Member

prury commented Aug 11, 2023

i'm still doing it mr bot

@yangwao
Copy link
Member

yangwao commented Aug 22, 2023

Any update @prury on this?
Can we have at least partial ones? 😄

@prury
Copy link
Member

prury commented Aug 22, 2023

Any update @prury on this? Can we have at least partial ones? 😄

@yangwao I do have an update, I've been messing with it in the past times, but since the number or PRs was very high i didn't had enough time.
1 - i am using pnpm install --frozen-lockfile in order for it no to update many other dependencies
2 - i did configure a baseURL:
image
3 - it automatically adds a action to the workflow folder
4 - i am able to run tests locally

problem:

The problem i am facing is related make playwright wait for Netlify to build in order to start the tests, every guide i was seeing uses a third party repo to implement it, examples: wait for netlify 1, wait for netlify 2, wait for netlify 3, and they are rarely being updated, if that's ok, then i'll use this solution, otherwise i want to ask for advice.

other sources: microsoft/playwright#9971

@preschian
Copy link
Member

The problem i am facing is related make playwright wait for Netlify to build in order to start the tests

no need to wait for Netlify. just run build and run localhost, and then run playwright to hit that localhost port. that is what we do on Cypress previously

- name: Run Cypress
timeout-minutes: 10
uses: Wandalen/wretry.action@v1.0.41
with:
command: pnpm start:static & pnpm wait-on http://localhost:9090 && MATRIX=${{ matrix.index }} node tests/cypress/e2e-run-tests.js
attempt_limit: 3

@prury
Copy link
Member

prury commented Aug 23, 2023

The problem i am facing is related make playwright wait for Netlify to build in order to start the tests

no need to wait for Netlify. just run build and run localhost, and then run playwright to hit that localhost port. that is what we do on Cypress previously

- name: Run Cypress
timeout-minutes: 10
uses: Wandalen/wretry.action@v1.0.41
with:
command: pnpm start:static & pnpm wait-on http://localhost:9090 && MATRIX=${{ matrix.index }} node tests/cypress/e2e-run-tests.js
attempt_limit: 3

thank you @preschian , will do it when i have the time

@prury prury mentioned this issue Aug 24, 2023
14 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
$$ ~51-150usd 🙄 - found some 🐛 and something WFM A-tests error-tracking p2 core functionality, or is affecting 60% of app
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants