|
|
|
|
@ -18,45 +18,41 @@ describe('Main Elements Render', function() { |
|
|
|
|
|
|
|
|
|
describe('side nav bar', () => { |
|
|
|
|
describe('render', () => { |
|
|
|
|
it('should show the logged username', () => { |
|
|
|
|
it('it should show the logged username', () => { |
|
|
|
|
sideNav.accountBoxUserName.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the logged user avatar', () => { |
|
|
|
|
it('it should show the logged user avatar', () => { |
|
|
|
|
sideNav.accountBoxUserAvatar.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the new channel button', () => { |
|
|
|
|
it('it should show the new channel button', () => { |
|
|
|
|
sideNav.newChannelBtn.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the plus icon', () => { |
|
|
|
|
it('it should show the plus icon', () => { |
|
|
|
|
sideNav.newChannelIcon.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the "More Channels" button', () => { |
|
|
|
|
it('it should show the "More Channels" button', () => { |
|
|
|
|
sideNav.moreChannels.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the new direct message button', () => { |
|
|
|
|
sideNav.newDirectMessageBtn.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show "general" channel', () => { |
|
|
|
|
it('it should show "general" channel', () => { |
|
|
|
|
sideNav.general.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show spotlight search bar', () => { |
|
|
|
|
it('it should show spotlight search bar', () => { |
|
|
|
|
sideNav.spotlightSearch.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
describe('spotlight search render', () => { |
|
|
|
|
it('should show spotlight search bar', () => { |
|
|
|
|
it('it should show spotlight search bar', () => { |
|
|
|
|
sideNav.spotlightSearch.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should click the spotlight and show the channel list', () => { |
|
|
|
|
it('it should click the spotlight and show the channel list', () => { |
|
|
|
|
sideNav.spotlightSearch.waitForVisible(5000); |
|
|
|
|
sideNav.spotlightSearch.click(); |
|
|
|
|
sideNav.spotlightSearchPopUp.waitForVisible(5000); |
|
|
|
|
@ -71,7 +67,7 @@ describe('Main Elements Render', function() { |
|
|
|
|
sideNav.spotlightSearchPopUp.isVisible().should.be.false; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should add text to the spotlight and show the channel list', () => { |
|
|
|
|
it('it should add text to the spotlight and show the channel list', () => { |
|
|
|
|
sideNav.spotlightSearch.waitForVisible(5000); |
|
|
|
|
sideNav.spotlightSearch.setValue('rocket.cat'); |
|
|
|
|
sideNav.spotlightSearchPopUp.waitForVisible(5000); |
|
|
|
|
@ -100,31 +96,31 @@ describe('Main Elements Render', function() { |
|
|
|
|
sideNav.accountBoxUserName.click(); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show user options', () => { |
|
|
|
|
it('it should show user options', () => { |
|
|
|
|
sideNav.userOptions.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show online button', () => { |
|
|
|
|
it('it should show online button', () => { |
|
|
|
|
sideNav.statusOnline.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show away button', () => { |
|
|
|
|
it('it should show away button', () => { |
|
|
|
|
sideNav.statusAway.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show busy button', () => { |
|
|
|
|
it('it should show busy button', () => { |
|
|
|
|
sideNav.statusBusy.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show offline button', () => { |
|
|
|
|
it('it should show offline button', () => { |
|
|
|
|
sideNav.statusOffline.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show settings button', () => { |
|
|
|
|
it('it should show settings button', () => { |
|
|
|
|
sideNav.account.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show logout button', () => { |
|
|
|
|
it('it should show logout button', () => { |
|
|
|
|
sideNav.logout.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
@ -138,11 +134,11 @@ describe('Main Elements Render', function() { |
|
|
|
|
sideNav.openChannel('general'); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the title of the channel', () => { |
|
|
|
|
it('it should show the title of the channel', () => { |
|
|
|
|
mainContent.channelTitle.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the empty favorite star', () => { |
|
|
|
|
it('it should show the empty favorite star', () => { |
|
|
|
|
mainContent.emptyFavoriteStar.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
@ -150,7 +146,7 @@ describe('Main Elements Render', function() { |
|
|
|
|
mainContent.emptyFavoriteStar.click(); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should not show the empty favorite star', () => { |
|
|
|
|
it('it should not show the empty favorite star', () => { |
|
|
|
|
mainContent.favoriteStar.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
@ -158,27 +154,27 @@ describe('Main Elements Render', function() { |
|
|
|
|
mainContent.favoriteStar.click(); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the message input bar', () => { |
|
|
|
|
it('it should show the message input bar', () => { |
|
|
|
|
mainContent.messageInput.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the file attachment button', () => { |
|
|
|
|
it('it should show the file attachment button', () => { |
|
|
|
|
mainContent.fileAttachmentBtn.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the audio recording button', () => { |
|
|
|
|
it('it should show the audio recording button', () => { |
|
|
|
|
mainContent.recordBtn.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the video call button', () => { |
|
|
|
|
it('it should show the video call button', () => { |
|
|
|
|
mainContent.videoCamBtn.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should not show the send button', () => { |
|
|
|
|
it('it should not show the send button', () => { |
|
|
|
|
mainContent.sendBtn.isVisible().should.be.false; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the emoji button', () => { |
|
|
|
|
it('it should show the emoji button', () => { |
|
|
|
|
mainContent.emojiBtn.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
@ -186,23 +182,23 @@ describe('Main Elements Render', function() { |
|
|
|
|
mainContent.addTextToInput('Some Text'); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the send button', () => { |
|
|
|
|
it('it should show the send button', () => { |
|
|
|
|
mainContent.sendBtn.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should not show the file attachment button', () => { |
|
|
|
|
it('it should not show the file attachment button', () => { |
|
|
|
|
mainContent.fileAttachmentBtn.isVisible().should.be.false; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should not show the audio recording button', () => { |
|
|
|
|
it('it should not show the audio recording button', () => { |
|
|
|
|
mainContent.recordBtn.isVisible().should.be.false; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should not show the video call button', () => { |
|
|
|
|
it('it should not show the video call button', () => { |
|
|
|
|
mainContent.videoCamBtn.isVisible().should.be.false; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the last message', () => { |
|
|
|
|
it('it should show the last message', () => { |
|
|
|
|
mainContent.lastMessage.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
@ -210,7 +206,7 @@ describe('Main Elements Render', function() { |
|
|
|
|
mainContent.lastMessageUser.getText().should.equal(username); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should not show the Admin tag', () => { |
|
|
|
|
it('it should not show the Admin tag', () => { |
|
|
|
|
mainContent.lastMessageUserTag.isVisible().should.be.false; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
@ -231,16 +227,16 @@ describe('Main Elements Render', function() { |
|
|
|
|
flexTab.operateFlexTab('info', false); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the room info button', () => { |
|
|
|
|
it('it should show the room info button', () => { |
|
|
|
|
flexTab.channelTab.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the room info tab content', () => { |
|
|
|
|
it('it should show the room info tab content', () => { |
|
|
|
|
flexTab.channelSettings.waitForVisible(5000); |
|
|
|
|
flexTab.channelSettings.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the room name', ()=> { |
|
|
|
|
it('it should show the room name', ()=> { |
|
|
|
|
flexTab.firstSetting.waitForVisible(); |
|
|
|
|
flexTab.firstSetting.getText().should.equal('general'); |
|
|
|
|
}); |
|
|
|
|
@ -256,11 +252,11 @@ describe('Main Elements Render', function() { |
|
|
|
|
flexTab.operateFlexTab('search', false); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the message search button', () => { |
|
|
|
|
it('it should show the message search button', () => { |
|
|
|
|
flexTab.searchTab.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the message tab content', () => { |
|
|
|
|
it('it should show the message tab content', () => { |
|
|
|
|
flexTab.searchTabContent.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
@ -274,17 +270,17 @@ describe('Main Elements Render', function() { |
|
|
|
|
flexTab.operateFlexTab('members', false); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the members tab button', () => { |
|
|
|
|
it('it should show the members tab button', () => { |
|
|
|
|
flexTab.membersTab.waitForVisible(5000); |
|
|
|
|
flexTab.membersTab.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the members content', () => { |
|
|
|
|
it('it should show the members content', () => { |
|
|
|
|
flexTab.membersTabContent.waitForVisible(5000); |
|
|
|
|
flexTab.membersTabContent.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the show all link', () => { |
|
|
|
|
it('it should show the show all link', () => { |
|
|
|
|
flexTab.showAll.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
@ -298,11 +294,11 @@ describe('Main Elements Render', function() { |
|
|
|
|
flexTab.operateFlexTab('notifications', false); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the notifications button', () => { |
|
|
|
|
it('it should show the notifications button', () => { |
|
|
|
|
flexTab.notificationsTab.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the notifications Tab content', () => { |
|
|
|
|
it('it should show the notifications Tab content', () => { |
|
|
|
|
flexTab.notificationsSettings.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
@ -316,11 +312,11 @@ describe('Main Elements Render', function() { |
|
|
|
|
flexTab.operateFlexTab('files', false); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the files button', () => { |
|
|
|
|
it('it should show the files button', () => { |
|
|
|
|
flexTab.filesTab.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the files Tab content', () => { |
|
|
|
|
it('it should show the files Tab content', () => { |
|
|
|
|
flexTab.filesTabContent.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
@ -334,11 +330,11 @@ describe('Main Elements Render', function() { |
|
|
|
|
flexTab.operateFlexTab('mentions', false); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the mentions button', () => { |
|
|
|
|
it('it should show the mentions button', () => { |
|
|
|
|
flexTab.mentionsTab.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the mentions Tab content', () => { |
|
|
|
|
it('it should show the mentions Tab content', () => { |
|
|
|
|
flexTab.mentionsTabContent.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
@ -352,11 +348,11 @@ describe('Main Elements Render', function() { |
|
|
|
|
flexTab.operateFlexTab('starred', false); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the starred messages button', () => { |
|
|
|
|
it('it should show the starred messages button', () => { |
|
|
|
|
flexTab.starredTab.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the starred messages Tab content', () => { |
|
|
|
|
it('it should show the starred messages Tab content', () => { |
|
|
|
|
flexTab.starredTabContent.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
@ -370,11 +366,11 @@ describe('Main Elements Render', function() { |
|
|
|
|
flexTab.operateFlexTab('pinned', false); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the pinned button', () => { |
|
|
|
|
it('it should show the pinned button', () => { |
|
|
|
|
flexTab.pinnedTab.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should show the pinned messages Tab content', () => { |
|
|
|
|
it('it should show the pinned messages Tab content', () => { |
|
|
|
|
flexTab.pinnedTabContent.isVisible().should.be.true; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
|