Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- it.only('C15052 - All channel types highlight properly on sidebar', () => {
- cy.visit('/');
- // should have remove button for DM/GM channels
- const publicChannelId = '7exhcp44dtru9gymohe5tms4de'; // should get dynamically
- cy.get(`#sidebarChannel_${publicChannelId}`).scrollIntoView().children().children().then(($el) => {
- assert.equal($el.length, 3, 'should have 3 children where last child is a remove button');
- assert.equal($el[2].id, `remove_${publicChannelId}`);
- cy.get(`#remove_${publicChannelId}`).should('not.be.visible');
- cy.get(`#remove_${publicChannelId}`).invoke('show').should('be.visible');
- });
- // should not have remove button for public or private channel
- const dmChannelId = 'xe617kybnjrr988i6mhds6rhdc'; // should get dynamically
- cy.get(`#sidebarChannel_${dmChannelId}`).scrollIntoView().children().children().then(($el) => {
- assert.equal($el.length, 2, 'should have 2 children only, no remove button');
- });
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement