Forum Discussion

Joberry's avatar
Joberry
Occasional Contributor
5 years ago

Exception running keyword test when called from another test

The automated testing sratergy we are embarking on is to record/handcrank simple Keyword tests (Units scripts when enhanced logic is required), large tests result in a large number of called keywords and scripts with normal while/if logic to contol which keywords are called.

 

This has been working well up untill today, when a test failed with an Exception (No additional info/help), the called test ran well on its own, but continued to fail when called,

 

The only solution I found was to copy the Test statements into the previous keyword test called (It was simply clicking on a button - now it clicks on the button and does stuff)

 

The stuff copied was not even very complex, a simple CTRL + D keypress and CTRL + S and close two windows.

 

This has lent me to thinking is there a limit to the number of keyword tests that can be called? (I personally would prefer to script everything, but I have been tasked to make it simple - hence record simple keywords - and then I stitch it all together and add the complex logic)

 

Todays issue has made me nervous as there was no clear reason for the error and the solution seems to show a weakness in our startergy (No limit to number of keywords appears in any documention, the only limitation I have found is one of Functionality, i.e why I would prefer to script)

 

9 Replies

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor

    Theoretically speaking, you are correct.  There's no limit to how "deep" your keyword test calls can be.  But, as with anything dealing with computer software, the limitations MAY be outside of the tool. If you consider call stack, you could have a memory limitation of how much memory is consumed if your keyword test calls are too deep.

      • Joberry's avatar
        Joberry
        Occasional Contributor

        I have now converted all the Keyword tests to Scripts (I am happier with scripts anyway!), I have raised a support ticket to ask this question more formally.

        #00427087: "Tests work until one more Keyword test is called then Test stops with Exception."

        I did look at Perfmon trace during the failed execution (Memory and CPU showed benine usage), The call stack showed 4 rows, so not eaxctly huge.