public void Test_Record_Binary_Display() { var algo = new TestAlgo(); try { algo.WithException(); } catch { } var data = Log.DumpToBinary(); var context = Log.DumpFromBinary(data); var output = LogPrinter.Print(context); Console.WriteLine(output); }
public void Test_Exception() { var algo = new TestAlgo(); bool exception = false; try { algo.WithException(); } catch { exception = true; } Assert.IsTrue(exception); var context = Log.DumpInMemory(); var output = LogPrinter.Print(context); Console.WriteLine(output); }
public void Test_Exception() { var algo = new TestAlgo(); bool exception = false; try { algo.WithException(); } catch { exception = true; } var output = GetOutput(); var ilalgo = WeaverHelper.CreateInstance <Yalf.TestAssembly.TestAlgo>(assembly); bool ilexception = false; try { ilalgo.WithException(); } catch { ilexception = true; } var iloutput = GetOutput(); Assert.That(exception, Is.True); Assert.That(ilexception, Is.True); var equal = String.Compare(output, iloutput, StringComparison.OrdinalIgnoreCase) == 0; Assert.That(equal, Is.True); }
private void RunException() { var algo = new TestAlgo(); algo.WithException(); }