1

Ideally all test cases are taking 4 to 5 mins to complete whole execution of automation in CI build server(VSTS build server), now the same set of test cases are taking more than 30mins or hanged when its getting failed, its not all moved to next scenario even failure.

I checked same set of test cases in my local machine, its getting 7 to 10 mins when its getting failed.

why its hanging on CI build server? please guide me on that..

if you require more information please revert me back

  • 2
    When you say now the same set of test cases are taking more than 30mins does that mean everything was working fine before? If yes, what changes had been introduced to your CI environment since that time when everything was fine? – Alexey R. Jan 17 '19 at 12:40
  • @Alexey R -Thanks for your response, none of the changes done in CI environment. it's hanging on Ci server when the test cases are fail. i could not track it because it's not thrown any exception or not moved to next step. – vijay r Jan 17 '19 at 14:07
  • There is too little information to go on in this question, tbh. But as a general triage example: it seems_something_ has changed. In your CI, in your general environment, in the code that is being build, in the order that steps are executed. So question1: did you go back to the last situation that everything worked? Question2: did you check all the logs? I just noticed your remark on 'local machine' which apparently(?) shows similar behaviour (failing?). Did it succeed before on your local machine? – Ray Oei Jan 17 '19 at 14:17
  • @Ray Oei - Thanks, Ans for Question1: none of code changes done from automation side since when worked everything fine. Ans for Question2: all logs seems good except recent execution, In my local machine i am not facing such issues like hanging on during failure.it's keep continued and complete the execution. – vijay r Jan 17 '19 at 14:35
  • I meant: did you rerun the last situation that everything worked including all code (automation AND product!) as it was at that stage? You need to go back to a known state that everything was OK and work your way up to the moment it starts failing. It is not only the CI automation that changes... as there is no reason to rerun your CI if nothing -to the codebase of your product- changed at all. – Ray Oei Jan 17 '19 at 15:18
1

Finally I found that, it's causing two issues to hanging my automation scripts,

1.I was magnifying the wait limit till the progress bar is active.

2.There is additional security question pop-up were prompted in Server machine which was not happened in local machine.

Thanks everyone for your valuable time.

0

If your tests keep hanging for a long time your framework should monitor them and cut them off after they exceeded their allowed runtime. I've found that multithreading is a good tool to do so since one Thread can spawn the Test and keep an eye on the time while the test does it's thing. If the runtime is exceeded you can kill the hanging thread and do whatever must be done to ensure the next test can run.

On which level do your tests run (Unit, Integration, System) and which Framework do you currently use?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.