cancel
Showing results for 
Search instead for 
Did you mean: 

Integration TestRail and TestComplete

SOLVED
Community Hero

Re: Integration TestRail and TestComplete

Hi,

 

HTTP status 200 means that sent request succeeded.

Nothing is expected to be opened because you are dealing with plain TestRail's API, but not TestRail web application itself.

The thread referenced above (https://community.smartbear.com/t5/TestComplete-General-Discussions/TestComplete-integration-with-Te...) contains pretty good description and code snippets.

Regards,
Alex
[Community Expert Group]
____
[Community Expert Group] members are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Postings made by [Community Expert Group] members
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
[Community Expert Group] signature is used with permission by SmartBear Software.
http://smartbear.com/forums/f83/t86934/community-experts/
================================
New Contributor

Re: Integration TestRail and TestComplete

Good afternoon!

I figured out how to put the results in TestRail through the API.
I can not understand how to run tests through TestRail? Has anyone done this?

Thanks for any answer.

I use TestComplect 10.50

Occasional Contributor

Re: Integration TestRail and TestComplete

Hi, 

 

I created a framework in Testcomplete that will read the tests inside a test run with a given test run-id.

Then, it would execute the corresponding test cases as read from the test run.  

At the end of each test case execution, the result of the test was returned via the API into TestRail.

 

As far as i know, there is no possibility to 'start' a test run or test case execution from within TestRail towards a (connected) Testtool.


Hope this helps. 

 

I'm gladly willing to share the framework as it is built in Testcomplete. (12 i believe, it has been a while... )

 

Good luck!

New Contributor

Re: Integration TestRail and TestComplete

@Sundaytwins, Thank you.

I will try to configure the launch of tests from TestRail. If I can write here Smiley Happy

Community Hero

Re: Integration TestRail and TestComplete

@Sundaytwins:

Hi,

 

> I'm gladly willing to share the framework as it is built in Testcomplete.

While SmartBear has not provided yet an area for solutions sharing (though they are considering this), you may contact @tristaanogre and talk to Robert to include your solution into the set of TestComplete-related goodies (https://bitbucket.org/account/user/privateteamogre/projects/CSE).

Regards,
Alex
[Community Expert Group]
____
[Community Expert Group] members are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Postings made by [Community Expert Group] members
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
[Community Expert Group] signature is used with permission by SmartBear Software.
http://smartbear.com/forums/f83/t86934/community-experts/
================================
New Contributor

Re: Integration TestRail and TestComplete

Dear SundayTwins,

 

Just wondering if you have published your framework anywhere yet ?

If your framework based on TestComplete's script extension ?

 

Thanks

aaron

New Contributor

Re: Integration TestRail and TestComplete

HI SundayTwins ,

 

Let me know if you were able to load this framework. I am trying to use the TestRail Api's to load the test results.

 

Thanks

Sachin

New Contributor

Re: Integration TestRail and TestComplete

"At the end of each test case execution, the result of the test was returned via the API into TestRail."

 

I would be interested to know how you can determine the pass/fail status of a test at the end of its execution. 

Because the test log is not generated(e.g., RootLogData.dat) until after all test items have been executed.

 

Someone suggested ErrCount object but unfortunately this property is not tied to a specific test items but it's accumulative.

New Contributor

Re: Integration TestRail and TestComplete

I know it is tooo late for answering but I hope someone will find this information useful. 

I was setting the integration between TC and TestRail and solved problem of saving results of each test this way: 

 

I added 2 global variables to project: 

Project.Variables.currentTestName = {testName}; // for example 1788
Project.Variables.currentTestStatus = 0;

 

And include them into each test. Each test has at the start

Project.Variables.currentTestName = {testName}; // for example 1788
Project.Variables.currentTestStatus = 0 

 

and at the end

Project.Variables.currentTestStatus = 1 

 

If test failes, status remaines 0.

 

To use these variables I created OnStopTest event - it works either test passes or failes. 

Code in the event looks like this: 

let caseId = Project.Variables.currentTestName;
let caseStatus = Project.Variables.currentTestStatus;
let testRailClient = new TestRailClient.TestRailClientClass(); 
testRailClient.sendResult(caseId, caseStatus);

 

Hope someone will find this useful. 

Regular Visitor

Re: Integration TestRail and TestComplete

Thank you @Eduardo !

Is there any way you can also share the class you are using here:
let testRailClient = new TestRailClient.TestRailClientClass(); 

New Here?
Join us and watch the welcome video:
Top Kudoed Authors