mirror of
https://github.com/0rangebananaspy/authelia.git
synced 2024-09-14 22:47:21 +07:00
78f6028c1b
Previously, logs were not very friendly and it was hard to track a request because of the lack of request ID. Now every log message comes with a header containing: method, path request ID, session ID, IP of the user, date. Moreover, the configurations displayed in the logs have their secrets hidden from this commit.
16 lines
450 B
TypeScript
16 lines
450 B
TypeScript
import { IMailSender } from "../../../src/lib/notifiers/IMailSender";
|
|
import BluebirdPromise = require("bluebird");
|
|
import Nodemailer = require("nodemailer");
|
|
import Sinon = require("sinon");
|
|
|
|
export class MailSenderStub implements IMailSender {
|
|
sendStub: Sinon.SinonStub;
|
|
|
|
constructor() {
|
|
this.sendStub = Sinon.stub();
|
|
}
|
|
|
|
send(mailOptions: Nodemailer.SendMailOptions): BluebirdPromise<void> {
|
|
return this.sendStub(mailOptions);
|
|
}
|
|
} |