Skip to content
This repository has been archived by the owner on Mar 13, 2024. It is now read-only.

Custom Status E2E tests #7564

Merged
merged 11 commits into from
Mar 15, 2021
Merged

Conversation

chetanyakan
Copy link
Contributor

@chetanyakan chetanyakan commented Feb 22, 2021

Summary

  • Added cypress tests for status dropdown and custom status modal
  • Added two support functions in cypress with documentation
  • Added e2e tests for Custom Status modal and status dropdown according to spec.
  • Added documentation above the custom status modal file and moved it to match the group
  • Added CSS classes in custom status modal

Related Links

Related Pull Requests

Screenshots

  1. cypress/integration/custom_status/custom_status_1_spec.js
    image

  2. cypress/integration/custom_status/custom_status_2_spec.js
    image

  3. cypress/integration/custom_status/custom_status_3_spec.js
    image

  4. cypress/integration/custom_status/custom_status_4_spec.js

  5. cypress/integration/custom_status/custom_status_5_spec.js
    image

  6. cypress/integration/custom_status/custom_status_6_spec.js
    image

@mattermod
Copy link
Contributor

Hello @chetanyakan,

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.

@esethna esethna requested a review from ogi-m February 22, 2021 15:37
@michelengelen michelengelen added 2: Dev Review Requires review by a core commiter 3: QA Review Requires review by a QA tester labels Feb 22, 2021
Copy link
Member

@devinbinnie devinbinnie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR @chetanyakan!
I've added some comments for you to review.

components/custom_status/custom_status_modal.tsx Outdated Show resolved Hide resolved
e2e/cypress/integration/menus/status_dropdown_spec.js Outdated Show resolved Hide resolved
package-lock.json Outdated Show resolved Hide resolved
e2e/cypress/integration/modals/custom_status_modal_spec.js Outdated Show resolved Hide resolved
manojmalik20 and others added 3 commits March 1, 2021 10:19
Added cypress tests for status dropdown and custom status modal
Added two support functions in cypress with documentation
Added some more tests in status dropdown
Added some more tests in custom status modal
Added documentation above the custom status modal file and moved it to match the group
Refactored and added 3 major tests for the custom status tests
Added some classes in custom status modal
Refactored and removed some tests from the status dropdown spec
- MM-T3851 Custom status CTAs for new users
- MM-T3850 Verifying where the custom status appears
- MM-T3852 Custom Status slash commands

- Reverted changes of package-lock.json
- Changed className to id in custom status modal and profile popover
@chetanyakan
Copy link
Contributor Author

Rebased to HEAD of master.

Copy link
Member

@devinbinnie devinbinnie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks again @chetanyakan, this is looking good.
Just one more comment before I approve.

package-lock.json Outdated Show resolved Hide resolved
Copy link
Member

@devinbinnie devinbinnie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good now, thanks @chetanyakan!

@hmhealey hmhealey removed the 2: Dev Review Requires review by a core commiter label Mar 2, 2021
@josephbaylon josephbaylon self-requested a review March 2, 2021 18:50
Copy link
Contributor

@josephbaylon josephbaylon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @chetanyakan ! Thanks for your contribution !! Here are some initial change requests.

The test file is huge and we want to try to minimize the number of tests in a file. Please break up the tests into several files as suggested below and don't include the // Stage: @prod into the new files.

Also, I'm getting several failures locally. Not sure which is causing which. Please make sure to run each separated test locally, grab a snapshot of each successful run and please include the snapshots in the PR description.

Here's a sample snapshot of a successful run you can take:
Screen Shot 2021-03-02 at 11 24 21 AM

Thanks! I'll re-review once the above changes are committed.

@chetanyakan
Copy link
Contributor Author

@josephbaylon Test case 4 has a weird behaviour.

It runs fine from the terminal, but fails when running from the cypress desktop app.

image

image

@chetanyakan
Copy link
Contributor Author

Strangely, I get different results using different version of Cypress.

@josephbaylon Can you verify on your end if any of the custom status E2E tests are failing?

Fixed post header CSS which does not work in Electron
Fixed issue with the recent custom statuses tests
Copy link
Contributor

@josephbaylon josephbaylon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @chetanyakan I retested locally and all tests pass for me locally! Thanks.

However, given that this is behind a feature flag, we cannot merge this until we set the value to true by default.

@ogi-m I'll approve the PR but I'll set the DO NOT MERGE label for now. We can revisit once the feature flag is enabled by default.

@josephbaylon josephbaylon added Do Not Merge/Awaiting Next Release To be merged with the next release (e.g. API documentation updates) Do Not Merge Should not be merged until this label is removed and removed Do Not Merge/Awaiting Next Release To be merged with the next release (e.g. API documentation updates) labels Mar 4, 2021
@hahmadia hahmadia added Work in Progress Not yet ready for review and removed Work in Progress Not yet ready for review labels Mar 4, 2021
Copy link

@ogi-m ogi-m left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@josephbaylon The feature flag is now enabled on master by default, can it be merged now?

@ogi-m ogi-m added 4: Reviews Complete All reviewers have approved the pull request and removed 3: QA Review Requires review by a QA tester labels Mar 9, 2021
@josephbaylon
Copy link
Contributor

/update-branch

@mattermod
Copy link
Contributor

We don't have permissions to update this PR, please contact the submitter to apply the update.

@josephbaylon
Copy link
Contributor

@hmhealey It seems like I lost rights to sync and merge. Please sync and merge. Thanks!

@josephbaylon josephbaylon removed the Do Not Merge Should not be merged until this label is removed label Mar 13, 2021
@josephbaylon
Copy link
Contributor

/update-branch

@mattermod
Copy link
Contributor

We don't have permissions to update this PR, please contact the submitter to apply the update.

@saturninoabril
Copy link
Member

/update-branch

@mattermod
Copy link
Contributor

We don't have permissions to update this PR, please contact the submitter to apply the update.

@saturninoabril
Copy link
Member

@chetanyakan Reviews complete. Please update so we can merge. Thank you for your contribution!

Joseph Baylon and others added 2 commits March 15, 2021 13:07
… cs-e2e

* 'master' of github.com:mattermost/mattermost-webapp: (26 commits)
  MM-33791 - add openId to check for account types (mattermost#7693)
  use theme variable for disabled select background (mattermost#7684)
  Fixed prod test cases (mattermost#7676)
  The pdf zoom level is store independently per file preview (mattermost#7635)
  fix broken test (mattermost#7694)
  Feature/MM 25430 show online status in channel switcher (mattermost#6609)
  [MM-31132] components/admin_console: enable metrics settings for TE (mattermost#7659)
  Added Guest account test cases (mattermost#7677)
  [MM-20397] Migrated the ChannelSelect component to TypeScript (mattermost#7436)
  [MM-33374] - Adding cloud license to dev environment causes sidebar menu to break (mattermost#7665)
  fixing group to channel modal (mattermost#7669)
  MM-33581 Fix off-by-one error in wrapEmojis (mattermost#7647)
  only apply theme variable in context of main app (mattermost#7649)
  MM-33661 Spurious "join private channel" warning fix (mattermost#7672)
  Translations update from Weblate (mattermost#7655)
  MM-23040: remove teamType prop from ChannelController (mattermost#7601)
  MM-3295 - remove no longer necessary validation (mattermost#7646)
  Disable check-deps ci step (mattermost#7657)
  fix group modal tests (mattermost#7513)
  [MM-33033] Use box-shadow for create post border instead of border (mattermost#7627)
  ...
@chetanyakan
Copy link
Contributor Author

@saturninoabril @josephbaylon Updated the branch.

@saturninoabril saturninoabril merged commit 0918d78 into mattermost:master Mar 15, 2021
@chetanyakan chetanyakan deleted the cs-e2e branch March 15, 2021 07:58
@amyblais amyblais added Changelog/Not Needed Does not require a changelog entry Docs/Not Needed Does not require documentation labels Mar 15, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
4: Reviews Complete All reviewers have approved the pull request Changelog/Not Needed Does not require a changelog entry Docs/Not Needed Does not require documentation
Projects
None yet