<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix">On 10/16/2013 01:57 PM, Petr Viktorin
      wrote:<br>
    </div>
    <blockquote cite="mid:525E7F36.4000507@redhat.com" type="cite">On
      10/14/2013 04:28 PM, Tomas Babej wrote:
      <br>
      <blockquote type="cite">Hi,
        <br>
        <br>
        When trying to create a new ordered test case by inheriting
        <br>
        from already defined test case, by overriding few of its
        methods,
        <br>
        the execution order of the tests is as follows:
        <br>
             - first all non-overriden test methods from the parent test
        class
        <br>
             - then all overriden tests methods
        <br>
      </blockquote>
      <br>
      That is not strictly true: if the base class is defined in a
      different file, with larger line numbers, with this patch its
      tests would run last.
      <br>
      <br>
      <blockquote type="cite">This patch makes sure that methods are
        executed in the logical order,
        <br>
        that is, the order defined in the parent class.
        <br>
      </blockquote>
      <br>
      We'll also need to support longer inheritance chains than just one
      parent.
      <br>
      The sort should look at the first @ordered superclass where the
      method was defined, and run the methods defined at the beginning
      of the inheritance chain first.
      <br>
      <br>
      I've modified your patch to accomplish this, does it look OK?
      <br>
      <br>
    </blockquote>
    <br>
    Thanks! This will even work with cross-module imports.<br>
    <br>
    I added a section to the Integration testing design page:
    <meta http-equiv="content-type" content="text/html;
      charset=ISO-8859-1">
    <a
href="http://www.freeipa.org/page/V3/Integration_testing#Ordering_of_the_tests">http://www.freeipa.org/page/V3/Integration_testing#Ordering_of_the_tests</a><br>
    <br>
    Also, I changed the commit message and comments to reflect the new
    behaviour.<br>
    <br>
    Updated patch attached.<br>
    <br>
    Tomas<br>
    <pre class="moz-signature" cols="72">-- 
Tomas Babej
Associate Software Engeneer | Red Hat | Identity Management
RHCE | Brno Site | IRC: tbabej | freeipa.org</pre>
  </body>
</html>