gurock / trcli

TR CLI (trcli) is a command line tool for interacting with TestRail.
Mozilla Public License 2.0
48 stars 39 forks source link

Test plan name for test runs #208

Open AlbertoValdivia20 opened 4 months ago

AlbertoValdivia20 commented 4 months ago

What would you like the TestRail CLI to be able to do?

Hello, I would like to have a way to add test runs to an specific test plan passing the name of the test plan, right now I only see a way to do it with the id.

My idea in a first instance it's to manage like suite: --suite-id Suite ID to submit results to. [x>=1] --suite-name Suite name to submit results to.

Why is this feature necessary on the TestRail CLI?

Because what I want is to use the same test plan for a whole month and create a new one for each month. The idea would be, I have in the pipeline this test plan name AUTOREGRESSION${ENV}_${monthAndYear} If it already exists add the test run, if not create a new test plan with that name.

More details

No response

Interested in implementing it yourself?

Yes

Testinator-X commented 4 months ago

What is your suggestion if someone has two plans with the same name? To which plan should the run then be added? Or should the import simply fail?

For more details on this discussion / a possible workaround see ticket #206.

AlbertoValdivia20 commented 4 months ago

I have been taking a look to --suite-name behaviour, and it uses the first one that you have, if you have two or more with the same name, I don't like this way too much, but I wouldn't mind to have it like that for plan-name.

From my point of view, it should fail warning the user, because if you have more than one with same name you should use id option, in fact I think it also should be fixed for suite options.

bitcoder commented 4 months ago

_The idea would be, I have in the pipeline this test plan name AUTOREGRESSION${ENV}${monthAndYear} If it already exists add the test run, if not create a new test plan with that name.

I'm not sure what I "feel" about the idea of creating test plans from the automation side. Usually a plan is something that we plan... ahead of time. Reporting against an existing test plan sound reasonable and it's a common practice. Whether we identify that plan by an ID or by a name.. I think that's something we can think a bit