static void Main(string[] args) { using (PostMockingDbContext context = new PostMockingDbContext()) { EmailSender emailSender = new EmailSender(); GeneradorInformes generador = new GeneradorInformes(context, emailSender); if (generador.GenerarInforme("FixedBuffer", "*****@*****.**")) { Console.WriteLine("Informe enviado con exito"); } else { Console.WriteLine("Problema al enviar el informe"); } } }
public GeneradorInformes(PostMockingDbContext context, IEmailSender emailSender) { this.context = context; this.emailSender = emailSender; }