There are already several threads about this in the stack overflow, but I ended my own solution from various sentences.
I used this FormatWith extension method to take care of simple templates, and then I made a base base base class to take care of common tasks, for example, pulling the appropriate template and replacing all the necessary information, as well as providing the Send () method.
All the emails I need to send have their own subclass coming from the database and define unique things for them, such as TemplateText, BindingData, Recipients and Subject. Having each of them in its class makes them very easy to unit test according to the rest of the application.
, , , (, , Send()), , , . , , , .
IEmail email = new MyEmailClass();
email.Send();
: : HTML/Email- ASP.NET?