title: Priority in TestNG with multiple classes
body: <p>I'm facing with the following problem: I created two classes which include @Tests with priority attribute:</p>
  
  <pre><code>@Test( priority = 1 )
  public void testA1() {
      System.out.println("testA1");
  }
  
  @Test( priority = 2 )
  public void testA2() {
      System.out.println("testA2");
  }
  
  @Test( priority = 3 )
  public void testA3() {
      System.out.println("testA3");
  }
  </code></pre>
  
  <p>... and ...</p>
  
  <pre><code>@Test( priority = 1 )
  public void testB1() {
      System.out.println("testB1");
  }
  
  @Test( priority = 2 )
  public void testB2() {
      System.out.println("testB2");
  }
  
  @Test( priority = 3 )
  public void testB3() {
      System.out.println("testB3");
  }
  </code></pre>
  
  <p>I put both classes under one test in testng.xml but when I run the test, it will order my @Tests based  on the priorities from both classes:</p>
  
  <pre><code>testA1
  testB1
  testA2
  testB2
  testA3
  testB3
  </code></pre>
  
  <p>I'm expecting the following result:</p>
  
  <pre><code>testA1
  testA2
  testA3
  testB1
  testB2
  testB3
  </code></pre>
  
  <p>My question is that how can I prevent to order my @Tests based on both classes and run @Tests only from one class at the same time?</p>