Пример #1
0
 public void TestConstructorLogEntryEventArgs()
 {
     ILogEntry entry = new ApplicationLogEntry(MessageType.Warning, null, new object());
     LogEntryEventArgs testLogEntryEventArgs = new LogEntryEventArgs(entry);
     Assert.IsNotNull(testLogEntryEventArgs, "Constructor of type, LogEntryEventArgs failed to create instance.");
     Assert.IsNotNull(testLogEntryEventArgs.LogEntry, "Constructor of type, LogEntryEventArgs failed to create instance.");
     Assert.IsTrue(entry.Equals(testLogEntryEventArgs.LogEntry), "Constructor of type, LogEntryEventArgs failed to create instance.");
 }
Пример #2
0
 private void LogManager_LogEntryAppended(object o, LogEntryEventArgs e)
 {
     if (e.LogEntry.Type == MessageType.Information)
     {
         if (Handle != IntPtr.Zero)
         {
             Invoke(new MethodInvoker(delegate()
             {
                 progressInfo.Text = e.LogEntry.Message;
                 Update();
             }));
         }
     }
 }
Пример #3
0
 void _unitUnderTest_LogEntryAppended(object o, LogEntryEventArgs e)
 {
     Trace.WriteLine("LogManager.LogEntryAppendedEvent");
 }
Пример #4
0
 public void TearDown()
 {
     _unitUnderTest = null;
 }
Пример #5
0
 public void SetUp()
 {
     _unitUnderTest = new LogEntryEventArgs(new ApplicationLogEntry(MessageType.Information, "Information", new object()));
 }