1
0
mirror of https://git.cloudron.io/cloudron/gitea-app synced 2025-09-01 23:35:06 +00:00

Use SMTPS port to send email for Go programs

This commit is contained in:
Girish Ramakrishnan
2018-01-18 11:01:41 -08:00
parent 99379fdbb3
commit d3553de1a6
2 changed files with 19 additions and 1 deletions

View File

@@ -220,6 +220,21 @@ return done();
expect(fs.existsSync(repodir + '/newfile')).to.be(true);
}
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 () {
execSync('cloudron build', { cwd: path.resolve(__dirname, '..'), stdio: 'inherit' });
});
@@ -262,6 +277,7 @@ return done();
});
it('can login', login);
it('can send mail', sendMail);
it('can set avatar', setAvatar);
it('can get avatar', checkAvatar);
@@ -350,6 +366,8 @@ return done();
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 clone the url', cloneRepo);
it('file exists in cloned repo', fileExists);