How to change Test Suite Description via Jenkins parameters

Best practices, code snippets for common functionality, examples, and guidelines.
Lyuba Boerma
Posts: 27
Joined: Mon Apr 01, 2019 12:12 pm

How to change Test Suite Description via Jenkins parameters

Post by Lyuba Boerma » Fri Jun 28, 2019 9:15 am

Hi)
Can i add/change Description of a Test suite via Jenkins parameters?
Is such parameter /variable exists for ranorex pluging ?
The reason why i need it - that we are running our tests on different customers installations, And i want to add Customers Name as a comment to a jenerated PDF report.
If i run it from my machine i always add it on a Description field.. But don't know how to do it via Jenkins

Option 2. I can also use for this a value of one of my Ranorex global parameters. But it need to be in a header of PDF report than.

What is possible?

Thanks)
jD.png
jD.png (22.28 KiB) Viewed 182 times

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 4967
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: How to change Test Suite Description via Jenkins parameters

Post by odklizec » Fri Jun 28, 2019 9:33 am

Hi,

I'm afraid, there is no way to edit the test suite description via command line/Jenkins plugin parameters? It may not even be possible via code? I think your best hope is using Global parameter. For basic report customization options, check these links:
https://www.ranorex.com/help/latest/ran ... thusername
https://www.ranorex.com/forum/adding-va ... 10821.html
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

Lyuba Boerma
Posts: 27
Joined: Mon Apr 01, 2019 12:12 pm

Re: How to change Test Suite Description via Jenkins parameters

Post by Lyuba Boerma » Fri Jun 28, 2019 3:41 pm

thanks. I found how to add my custom element to report.
But how to make him reed a value from Global Parameters?
cust.png
cust.png (21.87 KiB) Viewed 171 times

User avatar
RobinHood42
Posts: 298
Joined: Fri Jan 09, 2015 3:24 pm

Re: How to change Test Suite Description via Jenkins parameters

Post by RobinHood42 » Wed Jul 03, 2019 11:40 am

Hi Lyuba,

You simply need to pass the value from the global parameter to the created custom element.
TestSuite.Current.Parameters["MyGlobalVariable"];
Cheers,
Robin :mrgreen: