|
@@ -193,6 +193,21 @@ describe('Application life cycle test', function () {
|
|
});
|
|
});
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ function sendMail(done) {
|
|
|
|
+ browser.get('https://' + app.fqdn + '/admin/config').then(function () {
|
|
|
|
+ var button = browser.findElement(by.xpath('//button[@id="test-mail-btn"]'));
|
|
|
|
+ return browser.executeScript('arguments[0].scrollIntoView(true)', button);
|
|
|
|
+ }).then(function () {
|
|
|
|
+ return browser.findElement(by.xpath('//input[@name="email"]')).sendKeys('test@cloudron.io');
|
|
|
|
+ }).then(function () {
|
|
|
|
+ return browser.findElement(by.xpath('//button[@id="test-mail-btn"]')).click();
|
|
|
|
+ }).then(function () {
|
|
|
|
+ return browser.wait(until.elementLocated(by.xpath('//p[contains(text(),"Test email has been sent to \'test@cloudron.io\'")]')), TIMEOUT);
|
|
|
|
+ }).then(function () {
|
|
|
|
+ done();
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+
|
|
xit('build app', function () {
|
|
xit('build app', function () {
|
|
execSync('cloudron build', { cwd: path.resolve(__dirname, '..'), stdio: 'inherit' });
|
|
execSync('cloudron build', { cwd: path.resolve(__dirname, '..'), stdio: 'inherit' });
|
|
});
|
|
});
|
|
@@ -203,6 +218,7 @@ describe('Application life cycle test', function () {
|
|
|
|
|
|
it('can get app information', getAppInfo);
|
|
it('can get app information', getAppInfo);
|
|
it('can login', login);
|
|
it('can login', login);
|
|
|
|
+ it('can send mail', sendMail);
|
|
it('can set avatar', setAvatar);
|
|
it('can set avatar', setAvatar);
|
|
it('can get avatar', checkAvatar);
|
|
it('can get avatar', checkAvatar);
|
|
it('can add public key', addPublicKey);
|
|
it('can add public key', addPublicKey);
|
|
@@ -289,6 +305,8 @@ describe('Application life cycle test', function () {
|
|
execSync('cloudron install --wait --app ' + app.id, { cwd: path.resolve(__dirname, '..'), stdio: 'inherit' });
|
|
execSync('cloudron install --wait --app ' + app.id, { cwd: path.resolve(__dirname, '..'), stdio: 'inherit' });
|
|
});
|
|
});
|
|
|
|
|
|
|
|
+ it('can login', login);
|
|
|
|
+ it('can send mail', sendMail);
|
|
it('can get avatar', checkAvatar);
|
|
it('can get avatar', checkAvatar);
|
|
it('can clone the url', cloneRepo);
|
|
it('can clone the url', cloneRepo);
|
|
it('file exists in cloned repo', fileExists);
|
|
it('file exists in cloned repo', fileExists);
|