Merge remote-tracking branch 'origin/master' into MM-52097

Этот коммит содержится в:
yasserfaraazkhan
2023-04-18 17:50:03 +05:30
родитель b6f77e8bdc 067e36c23c
Коммит 965bca421a
1869 изменённых файлов: 11898 добавлений и 9548 удалений

Просмотреть файл

@@ -22,8 +22,6 @@ describe('New Channel modal with Boards enabled', () => {
cy.apiLogin(sysadmin);
cy.visit(`/${testTeam.name}/channels/town-square`);
});
cy.shouldHaveFeatureFlag('BoardsProduct', true);
});
it('MM-T5141 New Channel is created with an associated Board', () => {

Просмотреть файл

@@ -145,4 +145,42 @@ describe('Edit Message', () => {
cy.get(postText).should('have.text', `${secondMessage} Another new message Edited`);
});
});
it('MM-T5416 should discard any changes made after cancelling the edit and opening the edit textbox again should display the original message', () => {
const message = 'World!';
cy.postMessage(message);
// * Verify message is sent and not pending
cy.getLastPostId().then((postId) => {
const postText = `#postMessageText_${postId}`;
cy.get(postText).should('have.text', message);
// # Open edit textbox
cy.uiGetPostTextBox().type('{uparrow}');
// * Edit Post Input should appear, and edit the post
cy.get('#edit_textbox').should('be.visible');
// * Press the escape key to cancel
cy.get('#edit_textbox').should('have.text', message).type(' Another new message{esc}');
cy.get('#edit_textbox').should('not.exist');
// * Check that the message wasn't edited
cy.get(postText).should('have.text', message);
});
cy.getLastPostId().then((postId) => {
const postText = `#postMessageText_${postId}`;
cy.get(postText).should('have.text', message);
// # Open edit textbox again
cy.uiGetPostTextBox().type('{uparrow}');
// * Edit Post Input should appear, and edit the post
cy.get('#edit_textbox').should('be.visible');
// * Opening the edit textbox again after previously cancelling the edit should contain the original message.
cy.get('#edit_textbox').should('have.text', message);
});
});
});