public static Serilog.Core.Logger BuildSerilogLogFactory(SerilogConfiguration configuration = null)
        {
            (bool Buffered, bool Shared) = configuration ?? new SerilogConfiguration();

            return(new Serilog.LoggerConfiguration()
                   .WriteTo.File(
                       new Serilog.Formatting.Compact.CompactJsonFormatter(),
                       $"./serilog/audit-{DateTime.Now.ToString("yyyyMMddHHmm")}-latest.log",
                       Serilog.Events.LogEventLevel.Verbose,
                       100_000_000,

                       buffered: Buffered,
                       shared: Shared,

                       rollingInterval: Serilog.RollingInterval.Day,
                       rollOnFileSizeLimit: true)
                   .CreateLogger());
        }
 public SerilogTests(SerilogConfiguration configuration = null)
 {
     factory = LoggerBuilders.BuildSerilogLogFactory(configuration);
     logger  = factory.ForContext <IAuditLogger>();
 }