We are about to start the phase of updating test results in Rally via the api.
I couldn't find an example to do this via the web services API (e.g. posting xml). Can anyone point me to this?
Also I wondered what ability there is to do this in bulk, e.g. upload a set of test results in one go. Perhaps there are connectors for this that will upload various test result standards (e.g. JUnit report) into Rally?
Thoughts and ideas welcomed.
Thanks,
Andy
If you're doing a simple POST against the Test Case Result Create REST endpoint:
https://rally1.rallydev.com/slm/webservice/1.41/testcaseresult/create
Then the appropriate XML payload would be:
<TestCaseResult>
<Build>2345</Build>
<Date>2012-12-11T23:05:49.365Z</Date>
<TestCase ref="/testcase/12345678910"/>
<Tester ref="/user/12345678911"/>
<Verdict>Pass</Verdict>
</TestCaseResult>
Where the long integers are the ObjectID's of the TestCase to which the result associates, and the Rally User that is the tester.
I'll also include the JSON syntax, since Webservices 2.0 will be JSON-only:
https://rally1.rallydev.com/slm/webservice/1.41/testcaseresult/create.js
Payload:
{ "TestCaseResult" : {
"Build" : "2345",
"Date" : "2011-10-13T23:05:49.365Z",
"TestCase" : {
"_ref" : "/testcase/12345678910.js"
},
"Tester" : {
"_ref : "/user/12345678911.js"
},
"Verdict" : "Fail"
}
}
As far as I'm aware, there's not a pre-built connector for uploading JUnit results into Rally. Some customers find the Rally Excel Add-in to be useful for bulk uploading TestCaseResults, amongst other things. You just have to specify a column in your import worksheet that has the Rally ObjectID or FormattedID of the TestCase(s) to which you want to associate your results.
来源:https://stackoverflow.com/questions/15784748/rally-add-test-case-results-in-bulk-using-web-services-api