public project e2e
parent
b1f492e5c0
commit
bb2620dddd
|
@ -16,7 +16,8 @@ exports.config = {
|
|||
// },
|
||||
suites: {
|
||||
auth: 'e2e/auth/*.e2e.js',
|
||||
full: 'e2e/full/**/*.e2e.js'
|
||||
full: 'e2e/full/**/*.e2e.js',
|
||||
public: 'e2e/public/**/*.e2e.js'
|
||||
},
|
||||
onPrepare: function() {
|
||||
browser.driver.manage().window().maximize();
|
||||
|
|
|
@ -0,0 +1,91 @@
|
|||
var utils = require('../utils');
|
||||
|
||||
var chai = require('chai');
|
||||
var chaiAsPromised = require('chai-as-promised');
|
||||
|
||||
chai.use(chaiAsPromised);
|
||||
var expect = chai.expect;
|
||||
|
||||
describe('Public', async function(){
|
||||
before(async function(){
|
||||
browser.get('http://localhost:9001/project/project-3/admin/project-profile/details');
|
||||
|
||||
await utils.common.waitLoader();
|
||||
|
||||
$$('.privacy-settings input').get(0).click();
|
||||
|
||||
$('button[type="submit"]').click();
|
||||
|
||||
await utils.notifications.success.open();
|
||||
await utils.notifications.success.close();
|
||||
|
||||
return utils.common.logout();
|
||||
});
|
||||
|
||||
it('home', function() {
|
||||
browser.get('http://localhost:9001/project/project-3/');
|
||||
|
||||
utils.common.waitLoader();
|
||||
|
||||
utils.common.takeScreenshot('public', 'home');
|
||||
});
|
||||
|
||||
it('backlog', function() {
|
||||
browser.get('http://localhost:9001/project/project-3/backlog');
|
||||
|
||||
utils.common.waitLoader();
|
||||
|
||||
utils.common.takeScreenshot('public', 'backog');
|
||||
});
|
||||
|
||||
it('taskboard', function() {
|
||||
browser.get('http://localhost:9001/project/project-3/backlog');
|
||||
|
||||
utils.common.waitLoader();
|
||||
|
||||
$$('.sprints .button-gray').get(0).click();
|
||||
utils.common.waitLoader();
|
||||
|
||||
utils.common.takeScreenshot('public', 'taskboard');
|
||||
});
|
||||
|
||||
it('kanban', function() {
|
||||
browser.get('http://localhost:9001/project/project-3/kanban');
|
||||
|
||||
utils.common.waitLoader();
|
||||
|
||||
utils.common.takeScreenshot('public', 'kanban');
|
||||
});
|
||||
|
||||
it('us detail', function() {
|
||||
browser.get('http://localhost:9001/project/project-3/us/81');
|
||||
|
||||
utils.common.waitLoader();
|
||||
|
||||
utils.common.takeScreenshot('public', 'us-detail');
|
||||
});
|
||||
|
||||
it('issue detail', function() {
|
||||
browser.get('http://localhost:9001/project/project-3/issue/95');
|
||||
|
||||
utils.common.waitLoader();
|
||||
|
||||
utils.common.takeScreenshot('public', 'issue-detail');
|
||||
});
|
||||
|
||||
it('task detail', function() {
|
||||
browser.get('http://localhost:9001/project/project-3/task/2');
|
||||
|
||||
utils.common.waitLoader();
|
||||
|
||||
utils.common.takeScreenshot('public', 'task-detail');
|
||||
});
|
||||
|
||||
it('team', function() {
|
||||
browser.get('http://localhost:9001/project/project-5/team');
|
||||
|
||||
utils.common.waitLoader();
|
||||
|
||||
utils.common.takeScreenshot('public', 'us-detail');
|
||||
});
|
||||
});
|
|
@ -104,10 +104,26 @@ common.login = function(username, password) {
|
|||
}, 10000);
|
||||
};
|
||||
|
||||
common.logout = function() {
|
||||
browser.actions()
|
||||
.mouseMove($('div[tg-dropdown-user]'))
|
||||
.perform();
|
||||
|
||||
$$('.navbar-dropdown li a')
|
||||
.last()
|
||||
.click();
|
||||
|
||||
return browser.driver.wait(async function() {
|
||||
let url = await browser.driver.getCurrentUrl();
|
||||
|
||||
return url === 'http://localhost:9001/login';
|
||||
}, 10000);
|
||||
};
|
||||
|
||||
common.prepare = function() {
|
||||
browser.get('http://localhost:9001/');
|
||||
|
||||
return common.closeCookies()
|
||||
return common.closeCookies();
|
||||
}
|
||||
|
||||
common.dragEnd = function(elm) {
|
||||
|
|
Loading…
Reference in New Issue