Forum Discussion

krogold's avatar
krogold
Regular Contributor
5 years ago
Solved

test run takes longer than actual processing

Hello,

 

I have a test case with a groovy step. The step does some processing but it's a bit long so I logged info at the beginning and the end of the step. When I execute it I get my traces within the same second but processing actually takes several seconds. This occurs with or without teardown script.

Does anyone knows why this occurs ?

Is there any preference to set to avoid this ?

 

thank you

 

Alexandre

  • krogold's avatar
    krogold
    5 years ago

    Hello,

    Thank you for your responses. As I crossed informations from you and smartbear support, I tried to remove readyapi.h2.db and dashboard.h2.db from the db directory as, in my case, they were huge (over 600M and over 300M respectively) and now Ready API behaves as before.

    Test case execution is very fast and does no longer hangs. A testSuite execution that took 2 minutes with the hanging problem now takes 4 seconds.

    I'm not sure if its a stable and long lasting solution (and it seems that my project is corrupted on other features) but for now it solves that critical problem for me

7 Replies

  • groovyguy's avatar
    groovyguy
    Champion Level 1

    We are going to need some more details, but I do not think that this comes down to a simple preference that can be set. First, what is the groovy script doing? If it's parsing the response data that will take some time, especially if the response is large or if the script is inefficient. 

     

    Can you provde details on what the script is doing?

    • krogold's avatar
      krogold
      Regular Contributor

      Hi, in the mean time I changed my way of testing in order to see what's wrong, I've set a testcase with two "run test case" steps (calling the same REST API) for which I've set a logging trace in setup and teardown script, and a groovy step printing "stop". When I execute it it gives me the following :

      Mon May 27 15:27:47 CEST 2019: INFO: begin
      Mon May 27 15:27:47 CEST 2019: INFO: end
      Mon May 27 15:28:08 CEST 2019: INFO: begin
      Mon May 27 15:28:08 CEST 2019: INFO: end
      Mon May 27 15:28:13 CEST 2019: INFO: stop test

       

      As you can see, the gap between test steps is more than 20s.

      ReadyAPILog shows that REST request takes less than 100ms ...

       

      I don't understand what I've done to do this. It was working pretty fine before  :(:(

       

      • groovyguy's avatar
        groovyguy
        Champion Level 1

        How large is the response to the rest API calls? SoapUI processes the responses, applies pretty print, etc., and has to process any/all assertions. That 20s delay may be from that.