Ejemplo n.º 1
0
        public void LogMessage_ShouldHaveCorrectLoggingSection()
        {
            //Arrange
            LoggingSection loggingSection = new LoggingSection(this);
            LogMessage     logMessage;

            //Act
            logMessage = loggingSection.Log(LogLevel.INFO, "Test");

            //Assert
            Assert.NotNull(logMessage);
            Assert.Equal(loggingSection, logMessage.LoggingSection);
        }
Ejemplo n.º 2
0
        public void LogMessage_ShouldHaveCorrectMessage()
        {
            //Arrange
            LoggingSection loggingSection = new LoggingSection(this);
            LogMessage     logMessage;
            string         message = "Test";

            //Act
            logMessage = loggingSection.Log(LogLevel.INFO, message);

            //Assert
            Assert.NotNull(logMessage);
            Assert.Equal(message, logMessage.Message);
        }