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

MM-26069 Cypress test for MM-T622 which disallow override of username and profile picture #5814

Merged
merged 2 commits into from
Jun 30, 2020

Conversation

saturninoabril
Copy link
Member

@saturninoabril saturninoabril added 2: Dev Review Requires review by a core commiter 3: QA Review Requires review by a QA tester labels Jun 29, 2020
Copy link
Contributor

@Willyfrog Willyfrog left a comment

Choose a reason for hiding this comment

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

Added an improvement suggestion, but it doesn't block the pr

@@ -56,3 +58,26 @@ export function getMessageMenusPayload({dataSource, options, prefix = Date.now()
}

export const reUrl = /(https?:\/\/[^ ]*)/;

export const percentEncoding = {
Copy link
Contributor

Choose a reason for hiding this comment

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

not that it is bad, but wouldn't it be more complete if we use encodeURIComponent, that way you don't have to keep up with the list if we start using any other characters.

there is also an encodeURI if you don't care about components of it, but want to treat the whole uri

Copy link
Member Author

Choose a reason for hiding this comment

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

Oh right, thanks, I updated using encodeURIComponent since it's all I needed.

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.

LGTM. Code looks good. All tests passed.

Copy link
Contributor

@prapti prapti 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 to me!

});
});

it('MM-T622 Disallow override of username and profile picture', () => {
Copy link
Contributor

Choose a reason for hiding this comment

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

😄 🎉

@prapti prapti added 4: Reviews Complete All reviewers have approved the pull request and removed 2: Dev Review Requires review by a core commiter 3: QA Review Requires review by a QA tester labels Jun 30, 2020
@prapti prapti merged commit 110d6e4 into mattermost:master Jun 30, 2020
@amyblais amyblais added Changelog/Not Needed Does not require a changelog entry Docs/Not Needed Does not require documentation labels Jun 30, 2020
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
5 participants