using System.Collections.Generic;
public void SampleMethod()
public static void Main()
public static void ExecuteTests() {
var tests = new TestsFixture();
var failedTests = new List<string>();
foreach (var m in typeof(TestsFixture).GetMethods()
.Where(m => m.DeclaringType != typeof(object)))
if (Convert.ToBoolean(m.Invoke(tests, null)) != true)
Console.WriteLine("Failed Tests: \r\n\r\n{0}", string.Join("\r\n", failedTests));
Console.WriteLine("All tests passed!");
public class TestsFixture