|
|
|
|
@ -17,13 +17,14 @@ describe('Channel creation', function() { |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
beforeEach(()=>{ |
|
|
|
|
browser.pause(300); |
|
|
|
|
sideNav.getChannelFromList('general').waitForVisible(5000); |
|
|
|
|
sideNav.openChannel('general'); |
|
|
|
|
browser.pause(1000); |
|
|
|
|
browser.pause(300); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
afterEach(function() { |
|
|
|
|
if (this.currentTest.state !== 'passed') { |
|
|
|
|
if (this.currentTest.state !== 'passed' && this.currentTest.title !== 'should close the channel creation tab') { |
|
|
|
|
setPublicChannelCreated(false); |
|
|
|
|
switch (this.currentTest.title) { |
|
|
|
|
case 'create a public channel': |
|
|
|
|
@ -47,6 +48,10 @@ describe('Channel creation', function() { |
|
|
|
|
sideNav.createChannel(publicChannelName, false, false); |
|
|
|
|
setPublicChannelCreated(true); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should close the channel creation tab', function() { |
|
|
|
|
sideNav.channelType.isVisible().should.be.false; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
describe('create a private channel', function() { |
|
|
|
|
@ -54,6 +59,10 @@ describe('Channel creation', function() { |
|
|
|
|
sideNav.createChannel(privateChannelName, true, false); |
|
|
|
|
setPrivateChannelCreated(true); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should close the channel creation tab', function() { |
|
|
|
|
sideNav.channelType.isVisible().should.be.false; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
describe('direct channel', function() { |
|
|
|
|
@ -61,5 +70,9 @@ describe('Channel creation', function() { |
|
|
|
|
sideNav.startDirectMessage(targetUser); |
|
|
|
|
setDirectMessageCreated(true); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
it('should close the channel creation tab', function() { |
|
|
|
|
sideNav.channelType.isVisible().should.be.false; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
|