21 lines
777 B
JavaScript
21 lines
777 B
JavaScript
describe('The Room Page', () => {
|
|
it('displays new room entry with author name', () => {
|
|
// todo: mock all the graphql queries and mutations
|
|
|
|
cy.viewport('macbook-15');
|
|
cy.visit('/room/ein-historisches-festival');
|
|
cy.login('rahel.cueni', 'test');
|
|
|
|
cy.get('[data-cy=add-room-entry-button]').click();
|
|
cy.get('.add-content-element:first-of-type').click();
|
|
cy.get('[data-cy=choose-text-widget]').click();
|
|
cy.get('[data-cy=modal-title-input] > .modal-input__inputfield').type('some title');
|
|
|
|
let text = 'something should be here';
|
|
cy.get('[data-cy=text-form-input]').type(text);
|
|
cy.get('[data-cy=modal-save-button]').click();
|
|
|
|
cy.get('.room-entry__content:first').should('contain', text).should('contain', 'Rahel Cueni');
|
|
});
|
|
});
|