microsoft-test-manager

How to read parameter values from a TestCase in Microsoft Test Manager

牧云@^-^@ 提交于 2019-11-30 13:56:14
I am trying to execute the testcases programatically using the microsoft test manager using c#. For that I want to read the parameter values stored in Microsoft Test Manager. Please suggest me how to do that Eg:- Read the value of internal paramter "MY Value" I tried to enter the image but its not working ... Regards Harsh I suppose you want to read the parameters from the datasource of the Test Case that your automated test implements. You have to associate your test with the Test Case's Id on TFS. Try the following code. [TestClass] public class TestClass { public TestContext TestContext {

How to create a test run and result using the Team Foundation Server API?

情到浓时终转凉″ 提交于 2019-11-27 12:28:49
I have found several samples about retrieving test results using the TFS API, but no documentation on creating results programmatically. My aim is to create a lightweight alternative to using Microsoft Test Manager for running manual tests. Does anyone have experience with this? Are there any examples out there that I'm missing? Here's what I have so far: ITestCaseResult CreateNewTestCaseResult(ITestSuiteEntry testCaseEntry) { var run = testCaseEntry.TestSuite.Plan.CreateTestRun(false /* not automated */); run.AddTest(testCaseEntry.TestCase.Id, suiteEntry.TestSuite.DefaultConfigurations[0].Id,