fix e2e test when there is no watchers at the begining
parent
d0c02b66df
commit
d097ae4b88
|
@ -33,6 +33,8 @@ describe('modules', function() {
|
|||
|
||||
expect(utils.notifications.success.open()).to.be.eventually.equal(true);
|
||||
expect(active).to.be.false;
|
||||
|
||||
await utils.notifications.success.close();
|
||||
});
|
||||
|
||||
it('enable module', async function() {
|
||||
|
@ -53,6 +55,8 @@ describe('modules', function() {
|
|||
|
||||
expect(utils.notifications.success.open()).to.be.eventually.equal(true);
|
||||
expect(active).to.be.true;
|
||||
|
||||
await utils.notifications.success.close();
|
||||
});
|
||||
|
||||
it('enable videoconference', async function() {
|
||||
|
|
|
@ -99,7 +99,10 @@ describe('taskboard', function() {
|
|||
createTaskLightbox.subject().sendKeys(formFields.subject);
|
||||
await createTaskLightbox.description().sendKeys(formFields.description);
|
||||
|
||||
utils.common.takeScreenshot('taskboard', 'edit-task-filled');
|
||||
await utils.common.takeScreenshot('taskboard', 'edit-task-filled');
|
||||
|
||||
// send form fail when all tests are launched
|
||||
await browser.sleep(1000);
|
||||
});
|
||||
|
||||
it('send form', async function() {
|
||||
|
|
|
@ -118,9 +118,11 @@ helper.assignedTo = function() {
|
|||
clear: async function() {
|
||||
await browser.actions().mouseMove(el).perform();
|
||||
|
||||
el.$('.icon-delete').click();
|
||||
await utils.lightbox.confirm.ok();
|
||||
await browser.waitForAngular();
|
||||
if (await el.$('.icon-delete').isPresent()) {
|
||||
el.$('.icon-delete').click();
|
||||
await utils.lightbox.confirm.ok();
|
||||
await browser.waitForAngular();
|
||||
}
|
||||
},
|
||||
|
||||
assign: function() {
|
||||
|
@ -408,11 +410,11 @@ helper.watchers = function() {
|
|||
},
|
||||
|
||||
removeAllWathchers: async function() {
|
||||
let deleteIcons = await el.$$('.icon-delete')
|
||||
let deleteIcons = await el.$$('.icon-delete');
|
||||
let totalWatchers = deleteIcons.length;
|
||||
|
||||
while (totalWatchers > 0) {
|
||||
el.$$('.icon-delete').first().click()
|
||||
el.$$('.icon-delete').first().click();
|
||||
await utils.lightbox.confirm.ok();
|
||||
await browser.waitForAngular();
|
||||
totalWatchers --;
|
||||
|
|
|
@ -197,7 +197,10 @@ helper.watchersTesting = async function() {
|
|||
await watchersLightboxHelper.waitClose();
|
||||
|
||||
let newUserNames = await watchersHelper.getWatchersUserNames();
|
||||
expect(newUserNames.join()).to.be.equal(userNames + ',' + newWatcherName);
|
||||
|
||||
userNames.push(newWatcherName);
|
||||
|
||||
expect(newUserNames.join(',')).to.be.equal(userNames.join(','));
|
||||
|
||||
//Clear watchers
|
||||
await watchersHelper.removeAllWathchers();
|
||||
|
|
Loading…
Reference in New Issue