public void CreateTest_will_be_skipped_with_error_when_multiple_test_attributes_specified() { var tc = new ReflectedTestClass(typeof(PHasMethodWithMultipleAttributes)); var testContext = SelfTestUtility.NewTestContext(tc, new FakeRunner()); tc.InitializeSafe(testContext); var exec = new FakeTestExecutionContext(testContext, (TestCaseInfo)tc.Children[0], new PHasMethodWithMultipleAttributes()); var result = exec.RunCurrentTest(); Assert.Equal("Problem creating test (SpecException: Method has more than one fact or theory attribute)", result.Reason); Assert.True(result.Failed); }
protected override TestExecutionContext CreateChildContext(TestUnit test) { var result = new FakeTestExecutionContext(this, (TestCaseInfo)test, TestObject); return(result); }