mirror of
https://github.com/hanzoai/team.git
synced 2026-09-30 01:57:35 +00:00
* feat: run e2e full tests after successful smoke tests both in cypress and playwright * fix lint check on jsdoc req in playwright test * update smoke test filter * update test filter for cypress tests * update docker services, fix branch convention and rearrange secrets * update e2e-test workflow docs * reorganized * fix lint * fix playwright template * fix results assertion * add retest, e2e-test-verified, gh comments of failed tests, path filters, run e2e-tests check first and demote unstable tests * run using master image for e2e-only changes, add ts/js actions for cypress and playwright calculations, add verified by label --------- Co-authored-by: Mattermost Build <[email protected]>
59 lines
1.9 KiB
TypeScript
59 lines
1.9 KiB
TypeScript
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
|
|
// See LICENSE.txt for license information.
|
|
|
|
// ***************************************************************
|
|
// - [#] indicates a test step (e.g. # Go to a page)
|
|
// - [*] indicates an assertion (e.g. * Check the title)
|
|
// - Use element ID when selecting an element. Create one if none.
|
|
// ***************************************************************
|
|
|
|
// Group: @channels @messaging @benchmark
|
|
|
|
import {reportBenchmarkResults} from '../../../utils/benchmark';
|
|
|
|
describe('Message', () => {
|
|
before(() => {
|
|
// # Create new team and new user and visit off-topic channel
|
|
cy.apiInitSetup({loginAfter: true}).then(({offTopicUrl}) => {
|
|
cy.visit(offTopicUrl);
|
|
});
|
|
});
|
|
|
|
it('Current user posting message in empty channel', () => {
|
|
// # Wait for posts to load
|
|
cy.get('#postListContent', {timeout: 10000}).should('be.visible');
|
|
|
|
// # Reset selector measurements
|
|
cy.window().then((win) => {
|
|
win.resetTrackedSelectors();
|
|
|
|
// # Post message "One"
|
|
cy.postMessage('One');
|
|
|
|
cy.getLastPostId().then((postId) => {
|
|
const divPostId = `#postMessageText_${postId}`;
|
|
|
|
// * Check that the message was created
|
|
cy.get(divPostId).find('p').should('have.text', 'One');
|
|
|
|
reportBenchmarkResults(cy, win);
|
|
});
|
|
});
|
|
});
|
|
|
|
it('Typing one character into create post textbox', () => {
|
|
// # Wait for posts to load
|
|
cy.get('#postListContent', {timeout: 10000}).should('be.visible');
|
|
|
|
// # Reset selector measurements
|
|
cy.window().then((win) => {
|
|
win.resetTrackedSelectors();
|
|
|
|
// # Push a character key such as "A"
|
|
cy.uiGetPostTextBox().type('A').then(() => {
|
|
reportBenchmarkResults(cy, win);
|
|
});
|
|
});
|
|
});
|
|
});
|