I am implementing a custom ILogger (interface for logging) I have succesfully developed implementations of it with some famous loggers like Serilog or Log4Net. Now i want to create a memory logger, that stores all the logs inside a List (memory).
Since the List will only exist in the MemoryLogger:ILogger , I think that make it part of the contract of ILogger will be a bad workaround. I need some ideas about how to make that List accesible from the ILogger because it will be used in some Asserts in unit testing, for example. Do you have any ideas? Any workAround?