Tag: microsoft test manager

如何使用Team Foundation Server API创建测试运行和结果?

我找到了几个关于使用TFS API检索测试结果的示例,但没有关于以编程方式创建结果的文档。 我的目标是创建一个轻量级的替代方法,使用Microsoft Test Manager来运行手动测试。 有任何人对此有经验吗? 那里有没有我错过的例子吗? 这是我到目前为止所拥有的: ITestCaseResult CreateNewTestCaseResult(ITestSuiteEntry testCaseEntry) { var run = testCaseEntry.TestSuite.Plan.CreateTestRun(false /* not automated */); run.AddTest(testCaseEntry.TestCase.Id, suiteEntry.TestSuite.DefaultConfigurations[0].Id, suiteEntry.TestSuite.Plan.Owner); run.Save(); // so that results object is created return run.QueryResults()[0]; } 我不确定这是否是启动新运行的正确方法,我不确定如何记录测试的每个操作的结果。