Jenkins Configuration : Test Case failure

Best practices, code snippets for common functionality, examples, and guidelines.
csolanki
Posts: 120
Joined: Thu Mar 22, 2018 8:51 am

Jenkins Configuration : Test Case failure

Post by csolanki » Mon Feb 18, 2019 2:17 pm

Hi,

I have attached config. Please conclude it is failing due to miss of msbuild config. or due to test case problem.
Regards,
Charu Solanki
Ranorex User

csolanki
Posts: 120
Joined: Thu Mar 22, 2018 8:51 am

Re: Jenkins Configuration : Test Case failure

Post by csolanki » Mon Feb 18, 2019 2:18 pm

PFA
Attachments
Screenshot 2019-02-18 at 6.41.43 PM.png
Screenshot 2019-02-18 at 6.41.43 PM.png (78.29 KiB) Viewed 360 times
Regards,
Charu Solanki
Ranorex User

csolanki
Posts: 120
Joined: Thu Mar 22, 2018 8:51 am

Re: Jenkins Configuration : Test Case failure

Post by csolanki » Mon Feb 18, 2019 2:19 pm

PFA
Attachments
Screenshot 2019-02-18 at 6.42.37 PM.png
Screenshot 2019-02-18 at 6.42.37 PM.png (161.92 KiB) Viewed 360 times
Screenshot 2019-02-18 at 6.42.26 PM.png
Screenshot 2019-02-18 at 6.42.26 PM.png (255.48 KiB) Viewed 360 times
Screenshot 2019-02-18 at 6.42.11 PM.png
Screenshot 2019-02-18 at 6.42.11 PM.png (220.26 KiB) Viewed 360 times
Regards,
Charu Solanki
Ranorex User

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

Re: Jenkins Configuration : Test Case failure

Post by odklizec » Mon Feb 18, 2019 2:40 pm

Hi,

There appears to be multiple issues with your solution. At first, number of elements was not found. Have you tried to run the solution (on target machine) using Ranorex Studio? If no element is found, then there is most probably a problem with the xpath. The xpath either doe not work on target system or the search timeout is too short for given xpath. Are you sure the failing xpaths are OK?

At next, it seems you are using multiple test suites in your solution, therefore, you must specify (in command line/Ranorex plugin for Jenkins), which test suite should be started.
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

csolanki
Posts: 120
Joined: Thu Mar 22, 2018 8:51 am

Re: Jenkins Configuration : Test Case failure

Post by csolanki » Tue Feb 19, 2019 10:15 am

Yes, x-paths are okay and working. As they work in local. :/

But about multiple suites in one could be an issue. I have 13 suites in 1 test case. But each has its own set-up and close app. After 12th, they all 12 should get deleted in 13th suite.

Do I need to define each test suite differently in command line ?
Regards,
Charu Solanki
Ranorex User

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

Re: Jenkins Configuration : Test Case failure

Post by odklizec » Tue Feb 19, 2019 10:28 am

Hi,

I think you either use the test suites improperly or I'm missing something? Using 13 test suites just for 1 test case sounds crazy :) Could you please share a screenshot from test suite viewer?
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

csolanki
Posts: 120
Joined: Thu Mar 22, 2018 8:51 am

Re: Jenkins Configuration : Test Case failure

Post by csolanki » Tue Feb 19, 2019 11:44 am

PFA
Attachments
WorkFlow.PNG
WorkFlow.PNG (11.7 KiB) Viewed 345 times
Regards,
Charu Solanki
Ranorex User

csolanki
Posts: 120
Joined: Thu Mar 22, 2018 8:51 am

Re: Jenkins Configuration : Test Case failure

Post by csolanki » Tue Feb 19, 2019 11:48 am

PFA,
Attachments
WF3.PNG
WF3.PNG (26.96 KiB) Viewed 342 times
WF2.PNG
WF2.PNG (40.56 KiB) Viewed 342 times
WF1.PNG
WF1.PNG (37.01 KiB) Viewed 342 times
Regards,
Charu Solanki
Ranorex User

csolanki
Posts: 120
Joined: Thu Mar 22, 2018 8:51 am

Re: Jenkins Configuration : Test Case failure

Post by csolanki » Wed Feb 20, 2019 3:30 pm

Is it okay or need to refactor ?
Regards,
Charu Solanki
Ranorex User

User avatar
Vega
Posts: 153
Joined: Mon Jul 11, 2016 2:15 pm

Re: Jenkins Configuration : Test Case failure

Post by Vega » Fri Feb 22, 2019 10:02 pm

Is this being executed on the Jenkins machine itself or on an Agent / remote machine? Where ever it is being executed and is failing, try to take Jenkins out of the picture by just running the built test executable on the same machine.

Looking at the log, I would guess that perhaps the browsers on the machine are not instrumented. Your first step opens the browser and then immediately fails to find the first item:
forum1.png
forum1.png (63.87 KiB) Viewed 295 times
I would also suggest right clicking the open browser action -> properties -> and enabling the Instrument property to True. This will try to instrument the browser as it is opened.

hope this helps

csolanki
Posts: 120
Joined: Thu Mar 22, 2018 8:51 am

Re: Jenkins Configuration : Test Case failure

Post by csolanki » Mon Feb 25, 2019 3:28 pm

Hi,

thank you for suggesting this step, but already my instrument is on true.

Problem which I am encountering is : I am running it on Jenkins over headless chrome. headless chrome will not support any extensions. What could be done next ?
Regards,
Charu Solanki
Ranorex User

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

Re: Jenkins Configuration : Test Case failure

Post by odklizec » Mon Feb 25, 2019 3:34 pm

Hi,

As far as I know, headless testing (in Ranorex) is ONLY supported via webdriver integration! So if you want to run your tests headlessly, Selenium webdriver endpoint is your only option.
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

csolanki
Posts: 120
Joined: Thu Mar 22, 2018 8:51 am

Re: Jenkins Configuration : Test Case failure

Post by csolanki » Fri Mar 01, 2019 1:56 pm

Thank you, I am trying this approach. I will get back, if I face any other issue. :)
Regards,
Charu Solanki
Ranorex User