private void CallTestSetup(TestFixture testFixture, MethodInfo methodInfo) { try { testFixture.Setup(); } catch (Exception exception) { testFixture.SetClassName(testFixture.GetType().Name); testFixture.SetMethodName(methodInfo.Name); SetFixtureToFailed("Setup", testFixture, exception); } }
private void SetFixtureToFailed(string methodName, TestFixture testFixture, Exception exception) { testFixture.SetClassName(testFixture.GetType().Name); testFixture.SetMethodName(methodName); testFixture.Failed("An exception occured during " + methodName + "..." + exception.Message); }
private void CallTestMethod(TestFixture testFixture, MethodInfo methodInfo) { testFixture.SetClassName(testFixture.GetType().Name); testFixture.SetMethodName(methodInfo.Name); methodInfo.Invoke(testFixture, null); }