public void TestIsIgnore() { var entry = new UnityLogEntry(null, null, (LogType)100000); Assert.AreEqual(true, entry.IsIgnore(typeof(UnityConsoleLogHandler))); Assert.AreEqual(false, entry.IsIgnore(typeof(StdOutLogHandler))); }
public void TestInvalidLogTypeStack() { var entry = new UnityLogEntry(null, null, (LogType)100000); Assert.AreEqual(LogLevels.Emergency, entry.Level); Assert.AreEqual("[LogType Invalid]", entry.Message); }
public void TestGetCallStack() { var entry = new UnityLogEntry("helloworld", "hello\nworld", LogType.Log); Assert.AreEqual("hello", entry.GetStackTrace()[0]); Assert.AreEqual("world", entry.GetStackTrace()[1]); }
public void TestNullStack() { var entry = new UnityLogEntry(null, null, LogType.Log); Assert.AreEqual(0, entry.GetStackTrace().Length); }
public void TestNullMessage() { var entry = new UnityLogEntry(null, "hello\nworld", LogType.Log); Assert.AreEqual(string.Empty, entry.Message); }