Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8023263

[TESTBUG] Test closed/java/awt/Focus/InactiveWindowTest/InactiveFocusRace fails due to not enough time to initialize graphic components

XMLWordPrintable

    • generic
    • generic

      http://aurora.ru.oracle.com/functional/faces/RunDetails.xhtml?names=271403.JAVASE_EMBEDDED_PROMOTION_TESTCYCLE_8_ALL-21
      RULE closed/java/awt/Focus/InactiveWindowTest/InactiveFocusRace Exception java.lang.RuntimeException: Button2 didn't become focus owner

      To reproduce:
      go to bus2001047.us.oracle.com
      /net/aurora-ds/data/export/aurora/sca/embedded/builds/8/b101/jdk/linux-i586/bin/javac InactiveFocusRace.java
      /net/aurora-ds/data/export/aurora/sca/embedded/builds/8/b101/jdk/linux-i586/bin/javac InactiveFocusRace.html
      /export/local/aurora/CommonData/jtreg_dir/win32/bin/jtreg -verbose:all -testjdk:/net/aurora-ds/data/export/aurora/sca/embedded/builds/8/b101/jdk/linux-i586/ -dir:/export/users/rmatafon/ InactiveFocusRace.html

      Test will pass from time to time. Mostly fail.
      To make test pass ever, add code:

      try {
      Thread.sleep(1000);
      } catch (Exception e) {
      System.out.println("Oops");
      }

      after (line 83):

              inactiveFrame.setVisible(true);
              activeFrame.setVisible(true);

      BTW, test fails from time to time on my Core i5 notebook.

            psadhukhan Prasanta Sadhukhan
            rmatafon Roman Matafonov (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            14 Start watching this issue

              Created:
              Updated: