Menu

Order of tests

Help
2005-05-30
2013-04-25
  • Mika Hänninen

    Mika Hänninen - 2005-05-30

    Problem in our case that when selecting all the tests from different directories the QAT seems to execute them in random order.

    This results in faulty results in some cases, because when tests are ran seperately by directory test result is much better.

    How the order of the tests can be determined ?

    Best Regards,
    Mika

     
    • Web Hiker

      Web Hiker - 2005-05-30

      I've added an alphanumeric sort in the code now, so each directory of tests will be run in alphanumerically sorted order.

       
    • Web Hiker

      Web Hiker - 2005-05-30

      (continued...)
      So if you name your tests alphanumerically, they should be run in the correct order, or at least the same order every time.
      .
      Can you check out a cvs copy, build it, and see if it help your problem?
      Simply type "ant run" and it will build and run a version from the source code.

       
      • Mika Hänninen

        Mika Hänninen - 2005-05-30

        So does your fix work for situation when I have following situation in "Test selection"...?

        D_DIR
           - 001_test
           - XYZ_002_test
        ABC
           - 050_test
        OPOE
           - XYZ_003_test
           - 004_test

        When I select all tests I want it to execute 1st from D_DIR then from ABC and last from OPOE.

        Tests in order would be
        001_test
        XYZ_002_test
        050_test
        XYZ_003_test
        004_test

        Is this possible ?

        -Mika

         
    • Web Hiker

      Web Hiker - 2005-05-30

      Not exactly, but you could get this behaviour if you want.
      Essentially, all tests which are selected will be put into a flattened list, regardless of what sub-directories they are in.
      This list is then sorted alphanumerically, and run/evaluated.

      So as long as your tests in the OPOE directory come "after" the previous tests, it should work ok.

      If you want to, play around with the code (in src/qat/gui/TestTree.java) methods getAllTests*(*) and see if you can find a better method.

      Hope this help.

       

Log in to post a comment.