mattermost-webapp icon indicating copy to clipboard operation
mattermost-webapp copied to clipboard

Migrate /channel e2e tests to TypeScript

Open lucassabreu opened this issue 2 years ago • 21 comments

Summary

Convert following support files:

  1. e2e/cypress/tests/support/api/user.js
  2. e2e/cypress/tests/support/api/role.js

Ticket Link

https://github.com/mattermost/mattermost-server/issues/21299

Related Pull Requests

  • Has server changes (please link here)
  • Has mobile changes (please link here)

Screenshots

Release Note

NONE

lucassabreu avatar Oct 13 '22 13:10 lucassabreu

@lucassabreu: Adding the "do-not-merge/release-note-label-needed" label because no release-note block was detected, please follow our release note process to remove it.

I understand the commands that are listed here

mm-cloud-bot avatar Oct 13 '22 13:10 mm-cloud-bot

Hello @lucassabreu,

Thanks for your pull request! A Core Committer will review your pull request soon. For code contributions, you can learn more about the review process here.

Per the Mattermost Contribution Guide, we need to add you to the list of approved contributors for the Mattermost project.

Please help complete the Mattermost contribution license agreement? Once you have signed the CLA, please comment with /check-cla and confirm that the CLA check is green.

This is a standard procedure for many open source projects.

Please let us know if you have any questions.

We are very happy to have you join our growing community! If you're not yet a member, please consider joining our Contributors community channel to meet other contributors and discuss new opportunities with the core team.

mattermod avatar Oct 13 '22 13:10 mattermod

E2E tests not automatically triggered, because PR has no approval yet. Please ask a developer to review and then try again to attach the QA label.

mattermod avatar Oct 13 '22 13:10 mattermod

/check-cla

lucassabreu avatar Oct 14 '22 00:10 lucassabreu

@lucassabreu Can you please fix lint errors but running make check-style from /mattermost-webapp directory

furqanmlk avatar Oct 14 '22 17:10 furqanmlk

hi @furqanmlk , fixed the lint errors.

lucassabreu avatar Oct 15 '22 11:10 lucassabreu

/e2e-test

furqanmlk avatar Oct 15 '22 11:10 furqanmlk

Successfully triggered e2e testing! https://git.internal.mattermost.com/qa/cypress-ui-automation/-/pipelines/251259

mattermod avatar Oct 15 '22 11:10 mattermod

/e2e-test

lucassabreu avatar Oct 17 '22 23:10 lucassabreu

You don't have permissions to trigger this command. It's only available for organization members.

mattermod avatar Oct 17 '22 23:10 mattermod

/e2e-test

furqanmlk avatar Oct 18 '22 00:10 furqanmlk

Successfully triggered e2e testing! https://git.internal.mattermost.com/qa/cypress-ui-automation/-/pipelines/251915

mattermod avatar Oct 18 '22 00:10 mattermod

i run the e2e tests now for channels, all passed

lucassabreu avatar Oct 20 '22 02:10 lucassabreu

/e2e-test

furqanmlk avatar Oct 20 '22 20:10 furqanmlk

Successfully triggered e2e testing! https://git.internal.mattermost.com/qa/cypress-ui-automation/-/pipelines/253136

mattermod avatar Oct 20 '22 20:10 mattermod

just to report, i saw the failing tests at: https://automation-dashboard.vercel.app/cycles/28573f72-dbad-44b8-b924-50141b4c3292

and i am trying to fix them.

lucassabreu avatar Oct 21 '22 11:10 lucassabreu

just to report, i saw the failing tests at: https://automation-dashboard.vercel.app/cycles/28573f72-dbad-44b8-b924-50141b4c3292

and i am trying to fix them.

Thank you so much @lucassabreu

furqanmlk avatar Oct 21 '22 11:10 furqanmlk

@lucassabreu please re-assign when you are done with changes. Thanks

furqanmlk avatar Oct 21 '22 15:10 furqanmlk

hi @furqanmlk

running locally these two did not fail, so i don't know if i need to fix anything...

tests/integration/accessibility/accessibility_account_settings_spec.js tests/integration/enterprise/system_console/about/starter_edition_spec.js

this one is broken in the server... do i need to open a PR to the other repo? https://github.com/mattermost/mattermost-webapp/blob/a3afcdd881e8481ca4d69802d0bb42971d64e9f1/e2e/cypress/tests/integration/modals/quick_switcher_spec.js#L106

lucassabreu avatar Oct 27 '22 23:10 lucassabreu

/e2e-test

furqanmlk avatar Oct 27 '22 23:10 furqanmlk

Successfully triggered e2e testing! https://git.internal.mattermost.com/qa/cypress-ui-automation/-/pipelines/255781

mattermod avatar Oct 27 '22 23:10 mattermod

hi @furqanmlk i merged the changes from master into the PR again and looked into the last e2e-test run and there are a lot of "skippeds", there is something that i need to do?

https://automation-dashboard.vercel.app/cycles/bc9a533c-457a-4285-859d-d10188afa387

i also saw that some of the fixes that i did are on master now...

lucassabreu avatar Nov 03 '22 22:11 lucassabreu

hi @furqanmlk i merged the changes from master into the PR again and looked into the last e2e-test run and there are a lot of "skippeds", there is something that i need to do?

https://automation-dashboard.vercel.app/cycles/bc9a533c-457a-4285-859d-d10188afa387

i also saw that some of the fixes that i did are on master now...

Sorry @lucassabreu I got stuck on other tasks. Yeah, you might see fixes on support files as other contributors also migrating tests. The changes you are noticing are only new text, that has recently be updated. I think your fine. Can you please resolve the conflict?

furqanmlk avatar Nov 10 '22 21:11 furqanmlk

@lucassabreu sorry for the delay can you please fix conflict ? I would like to close this PR ASAP :)

furqanmlk avatar Nov 17 '22 16:11 furqanmlk

done @furqanmlk

lucassabreu avatar Nov 17 '22 16:11 lucassabreu

/e2e-test

furqanmlk avatar Nov 17 '22 17:11 furqanmlk

Successfully triggered e2e testing! https://git.internal.mattermost.com/qa/cypress-ui-automation/-/pipelines/263310

mattermod avatar Nov 17 '22 17:11 mattermod

@lucassabreu https://automation-dashboard.vercel.app/cycles/55ccfcc7-9d0b-4444-ae75-a4a123c5fb38

All Tests are failing due to

CypressError: cy.request() failed on:

http://server:8065/api/v4/users/email/[email protected]

The response we received from your web server was:

 401: Unauthorized

Can you run locally and see if it is failing ?

furqanmlk avatar Nov 17 '22 17:11 furqanmlk

@lucassabreu https://automation-dashboard.vercel.app/cycles/55ccfcc7-9d0b-4444-ae75-a4a123c5fb38

All Tests are failing due to

CypressError: cy.request() failed on:

http://server:8065/api/v4/users/email/[email protected]

The response we received from your web server was:

 401: Unauthorized

Can you run locally and see if it is failing ?

only in the weekend now @furqanmlk

lucassabreu avatar Nov 17 '22 17:11 lucassabreu

hi @furqanmlk the error shown does not happen for me locally, i am merging master on the PR again to see if it helps the test server.

lucassabreu avatar Nov 20 '22 18:11 lucassabreu