Open sebalanfranco opened 8 years ago
@xirsoi or @szymonh sorry to bother you guys, do you have any results.xml
sample since I´m getting some errors when trying to upload mine and there is not documentation about this plugin. Thanks in advance.
@sebalanfranco no problem, happy to help. The xml that the plugin accepts must comply with the xUnit Schema. Here's a very simple example:
`
`
Not sure why that wasn't formatted correctly...
EDIT: Just want to point out that that example is ridiculously simple. In the case of a fail, block, or error you would also include a message tag, which gives the reason for the failure/block/error.
Thank you @xirsoi for your answer! I really appreciate it. I find this plugin very helpful but I cannot get it working.
I´m still getting this error:
processing results.xml
ERROR: Publisher testrail.testrail.TestRailNotifier aborted due to exception
org.json.JSONException: JSONObject["title"] not found.
at org.json.JSONObject.get(JSONObject.java:473)
at org.json.JSONObject.getString(JSONObject.java:654)
at testrail.testrail.TestRailClient.createCaseFromJson(TestRailClient.java:264)
at testrail.testrail.TestRailClient.addCase(TestRailClient.java:278)
at testrail.testrail.TestRailObjects.ExistingTestCases.addCase(ExistingTestCases.java:112)
at testrail.testrail.TestRailNotifier.addSuite(TestRailNotifier.java:172)
at testrail.testrail.TestRailNotifier.perform(TestRailNotifier.java:123)
at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:772)
at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:736)
at hudson.model.Build$BuildExecution.post2(Build.java:183)
at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:685)
at hudson.model.Run.execute(Run.java:1757)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:88)
at hudson.model.Executor.run(Executor.java:234)
Finished: FAILURE
This appears to be an error related to creating new Test Cases in TestRail based on your test results. TestRail isn't responding with the data expected. I would double check the credentials you configured the plugin with (in Jenkins' Global Settings). Make sure the user you gave has permissions to create new test cases.
Hi guys. Sorry for not responding for a while. I'm not working with TestRail anymore, so it's hard for me to figure out the issues. If you willing to take over the pluging improvement/bugfixing - please feel free to do it.
I'd be willing to contribute more heavily. My company isn't using this plugin as a solution anymore, but we are still using TestRail and sending results to it, so I have some familiarity with the API.
Thank you @xirsoi ! I'll double check my credentials on TestRail and I'll back to you if you don't mind. No problem @achikin, thank you anyway. May I keep this issue open until I get a solution or find the root cause of my issue?
Make sure to also check the permissions for the TestRail user you've created.
I´m getting the following error when I try to upload results to TestRail using this plugin. Could you please just provide a sample of the results.xml accepted by the plugin so we base on it to generate ours?