Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add XMLRPC services to manage ITS #210

Open
wants to merge 12 commits into
base: testlink_1_9_20_fixed
Choose a base branch
from

Conversation

atisne
Copy link
Contributor

@atisne atisne commented Aug 2, 2019

Create, Update, Link an ITS with a test project via XMLRPC API
Useful to easily interface Testlink from external bug trackers (plugins)

atisne added 2 commits August 2, 2019 10:10
@squash-labs
Copy link

squash-labs bot commented Aug 2, 2019

Manage this branch in Squash

Test this branch here: https://atisnefeature-api-manage-its-su5sw.squash.io

@@ -3162,6 +3162,7 @@ $TLS_API_NO_TESTSUITEID = "No testsuiteid provided.";
$TLS_API_NO_TPID = "No testplan ID (testplanid) provided.";
$TLS_API_NO_TCID = "No testcase ID (testcaseid) provided.";
$TLS_API_NO_PLATFORMID = "No Platform ID (platformid) provided.";
$TLS_API_NO_ITSID = "NO ITS ID (itsid) provided.";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please provide a better message => NO Issue Tracker Sistem ID ....

@@ -216,6 +216,10 @@ class TestlinkXMLRPCServer extends IXR_Server {
public static $testCaseVersionParamName = "tcversion";
public static $itsNameParamName = "itsname";
public static $itsEnabledParamName = "itsenabled";
public static $itsTypeParamName = "itstype";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do not think an specific name is needed => parameter can be named only 'type'
same per enabled, same per cfg, probably same for id

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I changed some. But I'm really not sure we can always safely use attribute names without typed them. Especially some that may be used in the same time with others concepts. It may results conflicts.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know that in the past this approach has been the rule, but IMHO in some moments is an overkill.
Then I prefer to think about a solution if the situation will happens

regards

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the situation happens, you will must broke the API. It's a big impact, isn't it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not going to happen if people pay attention to what is doing, testing

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure to well understand.

Imagine I want to add a service to link a test project to an ITS. This service will take as input a test project ID and an ITS ID. Both parameters cannot have the same name ('id'). These names are used as array keys. So we must name them differently ('testprojectid' and 'itsid').
If we rename later a parameter to avoid this kind of conflict, we will break the API and will impact existing code that use it.
That's why I think it's better to distinguish parameter names without presuming the future.
If parameter names have the same names, we cannot use them together. And if we change them later, we will break existing stuff.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nodoby have said that testprojectid parameter name has to be changed to id, but that itsid can be changed to id.
Then my choice is wait for requested changet to accept the code.

In addition:

  • sample php clients to test implementation are a good things to do
  • create the method to remove link between test project and issue tracking system is IMHO needed. I've not fully read the code maybe implementation has been done passing 0 as ITS id using the set method

Copy link
Contributor Author

@atisne atisne Aug 6, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nodoby have said that testprojectid parameter name has to be changed to id, but that itsid can be changed to id.

Sure. But I think it's not a good idea to not have a global rule. In which cases I can or I cannot?...

Then my choice is wait for requested changet to accept the code.

I don't understand what do you mean here.

In addition:

* sample php clients to test implementation are a good things to do

Do you have guidelines to do this?

* create the method to remove link between test project and issue tracking system is IMHO needed. I've not fully read the code maybe implementation has been done passing 0 as ITS id using the set method

You're right. I will try to add it.

@atisne
Copy link
Contributor Author

atisne commented Aug 30, 2019

Hi Francisco,

I've amended the request as you suggested. Could you please reconsider it?

@atisne atisne changed the base branch from testlink_1_9 to testlink_1_9_20_fixed July 24, 2020 13:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants