escape the email
This commit is contained in:
parent
1c08896f2d
commit
86152e3f99
@ -17,11 +17,16 @@ exports = module.exports = {
|
||||
getOwner: getOwner,
|
||||
getAdmin: getAdmin,
|
||||
stripeSecret: stripeSecret,
|
||||
stripUnreachable: stripUnreachable
|
||||
stripUnreachable: stripUnreachable,
|
||||
regexp: regexp
|
||||
};
|
||||
|
||||
var gEcosystem = safe.require(path.join(__dirname, '../secrets/e2e-test/ecosystem-staging.json'));
|
||||
|
||||
function regexp(str) {
|
||||
return new RegExp(str.replace(/[-\/\\^$*+?.()|[\]{}]/g, '\\$&'));
|
||||
}
|
||||
|
||||
function cloudronDomain(filename) {
|
||||
return 't' + path.basename(filename.replace(/-/g,''), 'test.js') + '.selfhost.io';
|
||||
}
|
||||
|
@ -81,8 +81,8 @@ describe('Cloudron backup testing', function () {
|
||||
|
||||
it('did send mail from cloudron user', function (done) {
|
||||
imap.probe({
|
||||
subject: new RegExp('^Hi from e2e test - ' + cloudron.fqdn() + '$'),
|
||||
to: new RegExp('test+' + cloudron.fqdn() + '@cloudron.io'),
|
||||
subject: common.regexp('^Hi from e2e test - ' + cloudron.fqdn() + '$'),
|
||||
to: common.regexp('test+' + cloudron.fqdn() + '@cloudron.io'),
|
||||
body: /This release depends on you/
|
||||
}, done);
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user