tfs sdk - TFS API - Search For Test Case by custom field "Extended ID", in a specific hierarchy, then update its result -
i'm new tfs api. have looked around found incomplete solutions problems.
what want search specific test case custom field "extended id" = "ext:123" in test plan id = 104, , test suite id = 1455. maybe there 2 parts question.
1) testsuiteid unique throughout entire test plans within project? if not, have search specific test suite digging downwards hierarchy "project"-->"testplan"-->"testsuite". how do that?
2) kindly show me how search specific test case custom field "extended id" = "ext:123" within specific test suite?
so far, have
string tfsurl = "http://tfs:8080/tfs/defaultcollection"; string projectname = "myproduct"; int testplanid = 111; int testsuiteid = 2222; int extendedid = "ext:123"; itestmanagementteamproject proj = getproject(tfsurl, projectname); var tps = proj.testplans; var tp = tps.find(testplanid); // how find test suite within test plan? // searching test suite id within project works if unique throughout test plans within project var tss = proj.testsuites; var ts = tss.find(testsuiteid); // works var tcs = ts.alltestcases; foreach (var tc in tcs) { // want find test case custom field "extended id" matches "ext:123" if (tc.??????? == extendedid) { var testresults = proj.testresults.bytestid(tc.id); // how update test result? thanks in advance!!
tc.customfields["extended id"]. besides, test result associated testpoint (a combination of test case , configuration) in testrun. 1 test case may have many test results. need know , specify result want update.
tfs tfs-sdk microsoft-test-manager
No comments:
Post a Comment