Join 34,000+ subscribers and receive articles from our blog about software quality, testing, QA and security.
 

Feature request TestRail - Fogbugz integration


#1

Hi,
I’m trying out the integration of TestRail with FogBugz.
I set the link up during the project creation.

Situation:
I have a Test run assigned to me,
I execute a Test Case, but it fails.
I want to add a defect.

The “Add” link points me correctly to my FogBugz account,
but shows an empty “New Case” window.

I think it’d be great feature if users could use
placeholders in the url to the bugtracking system,
to be able to pre-fill in some fields.

The Fogbugz API supports this: http://www.fogcreek.com/FogBugz/docs/70/topics/advanced/API.html and I’m sure others too.

Right now you can already pass along the FogBugz project id,
provided it is fixed per TestRail project:
Defect Add Url:
http://your-name.fogbugz.com/default.asp?command=new&pg=pgEditBug&ixProject=7

I’m thinking about

&sTitle=[Title of the Test Case] - [Title of the Test Run]"
&sEvent = “Failed: [description of the Test Case]”

Possibilities are endless!

Jan


#2

Hello Jan,

Thanks for your message. We plan to improve the bug tracker integration in the future and want to provide a ‘push defect’ functionality to automatically create bug entries based on test results. We are also looking into writing plugins for some of the more popular bug trackers at some point (likely FogBugz and Jira) to allow a two-way integration.

I have a question about your suggestion though: you mentioned that the API can be used to pre-fill the values. Are you sure this is the way it works? If I understood it correctly, the API can be used to automatically add bug entries (and a lot of other stuff) and receive an XML reply. We plan to make use of it ‘behind-the-scenes’ to add bug entries automatically.

If it can also be used to pre-fill values, this would indeed be a good interim solution before we find the time to integrate the full API.

Regards,
Dennis


#3

The documentation is indeed about something slightly different: it’s about the XML API which works ‘behind the scenes’.
The Add defect link currently available in TestRail just opens an URL where you can ‘manually’ enter a new defect/FogBugz Case.

But, the arguments mentioned in the XML API documentation also work with this URL:

Example:
My current TestRail project has a Defect Add Url like this:

Because I added the arguments sTitle and ixProject,
these 2 values are used to ‘pre-fill’ the FogBugz fields of the new case:
the “New Case” screen has in Title the default text "testing"
and the default Project is the FogBugz project I want coupled to the TestRail project.
This way, I don’t have to select it anymore: the new case will automatically be created in the correct Fogbugz project.
(I found the index of the Fogbugz project in the URL of the Fogbugz Filter screen)

The text ‘testing’ is obviously just hard-coded testing.
My feature request was to provide the possibility to pass a title like:
“Test [id testcase] failed: [description testcase]”

There are a lot more possibilities indeed for interaction between FogBugz and TestRail,
but your development effort would be limited to FogBugz users.
I suspected this one was rather simple to implement, and not limited to FogBugz, becasue the other defect trackers probably/hopefully also support arguments in their URL’s.

Thanks in advance!


#4

Thanks for the clarification Jan. I wasn’t aware of the fact that FogBugz also supports URL parameters to pre-fill the values. This really makes sense, though I’m not sure how many other tools support this.

We will look into this more closely over the next weeks. If this fits into our long-term plans for bug tracker integration, we could certainly add support for additional bug tracker parameters to one of the next releases.

Thanks!

Regards,
Dennis


#5

Bugzilla also supports this functionality and I would also like to add my name into the list for this support.


#6

Thanks, I didn’t know Bugzilla also supports this. We will definitely look into this feature and consider it for the next versions.

Regards,
Dennis


#7

Just so you have the syntax and how to do this:

Go to the create page in bugzilla to file a new bug. Make sure you have advanced fields turned on (3.4.x or greater). Fill out all of the fields you want as your template, and then at the bottom of the screen, click on the Make a Bookmarkable Template.

The resulting URL will be something like the below:

https://bugzilla.com/enter_bug.cgi?assigned_to=email%40company.com&blocked=&bug_file_loc=http://&bug_severity=normal&bug_status=NEW&cf_aptestid=&cf_build=&cf_cr=&cf_releasenoterequired=—&cf_requirement=&cf_subcase=&comment=&component=Provisioning&contenttypeentry=&contenttypemethod=autodetect&contenttypeselection=text/plain&data=&deadline=&dependson=&description=&estimated_time=0.0&form_name=enter_bug&maketemplate=Remember%20values%20as%20bookmarkable%20template&op_sys=All&priority=P3&product=PTF&qa_contact=&rep_platform=All&short_desc=&target_milestone=—&version=1.2.0


#8

Thanks Steve, that’s very useful! We will make sure to mention some of the standard arguments in the documentation if/when we have this functionality.

Regards,
Dennis


#9

Just as a follow on question here…

I have my system setup to pre-fill out a bunch of information when someone clicks “Add” from adding a test result, which populates a number of fields in Bugzilla based on the team that is using TestRail.

One of the fields that Bugzilla has is a URL field which is usually used to link back to external systems that generated the bug or that have data on it.

I would like to include the URL to the test case or test suite/run that is being used to generate the bug, but I can’t figure out how to do that. I know that there is an %id% keyword for referencing bug IDs for the defect side of things, but is there a way to include the URL in the actual Add dialog, or is this one of those things you’re looking at for the future?


#10

Hello Steve,

Thanks for the suggestion. This would be something that we would support when we added additional placeholders for the bug tacker integration to TestRail. At the moment there is just the %id% placeholder for the View Defect URL and we don’t have something similar for the Add URL at the moment. I will make sure to add this suggestion to the actual feature request in our database so that we can consider it when such a feature gets implemented.

Regards,
Dennis