18 January 2026:


This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.



Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.

What is the order of execution of the tests when using _runUnitTests()

mjmckaymjmckay Members
edited November -1 in Sahi - Open Source
Hello,

What determines the order of execution of the test functions when you use _runUnitTests()?

Mike.

Comments

  • Hi Mike,

    _runUnitTests() executes all functions whose name starts with “test”. If functions setUp() and tearDown() are defined, they are executed before and after each test, irrespective of errors in the test functions.

    Regards
    Sumitra
  • Thanks Sumitra,

    The questions was what in what order the function _runUnitTests() runs the functions whose name starts with "test". If I have dependencies between these functions where one test sets conditions required by another test, how can I ensure they are executed in the proper sequence?

    Mike.
  • I am new to the Sahi and started playing with _runUnitTests() function. i was actually looking for finding the order of execution. can you help me in understanding the order of execution. I found it is bottom to top, is there any reason why it is like that?
Sign In or Register to comment.