<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <p>Test names are never changed during test execution.<br>
    </p>
    <p>Postfixes, as you call them, are added when the test is read when
      you have multiple test descriptions (comments beginning @test) in
      the same file. <br>
    </p>
    <p>They've always been added for the 2nd and subsequent test
      descriptions in a file; the recent change is to add them for the
      first test in a file when the file has multiple tests. This is for
      uniformity and to be able to disambiguate between specifying "all
      the tests in a file" vs. "the first test in a file."</p>
    <p>Note that putting multiple test descriptions in a single file has
      never been formally supported, because of the potential ambiguity
      that was (finally) resolved by the recent change.<br>
    </p>
    -- Jon<br>
    <br>
    <div class="moz-cite-prefix">On 5/30/17 8:06 PM, Vitaly Provodin
      wrote:<br>
    </div>
    <blockquote
      cite="mid:97EA89AE-E6F8-49AB-8092-9F427EE06681@jetbrains.com"
      type="cite">
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
      <div class="">Hi all,</div>
      <div class=""><br class="">
        <div class="">Running JDK regression tests via jtreg I detected
          that names of some tests can be changed during test execution.
          Namely, some postfix is added at the end of test name like
          follows:</div>
        <div class="">===================================8<-------------------------------------------------------------</div>
        <div class="">
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">#Mon May 29 18:56:12 MSK
              2017</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">#-----testdescription-----</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">$file=/opt/buildAgent/work/9d35cf148e807375/test/java/awt/Focus/AutoRequestFocusTest/AutoRequestFocusSetVisibleTest.java</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">$root=/opt/buildAgent/work/9d35cf148e807375/test</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">author=anton.tarasov\:
              area\=awt.focus</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">id=id0</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">keywords=bug6187066</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">library=../../regtesthelpers</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">run=USER_SPECIFIED build
              Util\nUSER_SPECIFIED main AutoRequestFocusSetVisibleTest\n</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">source=AutoRequestFocusSetVisibleTest.java</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">title=Tests the
              Window.autoRequestFocus property for the
              Window.setVisible() method.</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961); min-height: 14px;" class=""><span
              style="font-variant-ligatures: no-common-ligatures"
              class=""></span><br class="">
          </div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">#-----environment-----</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961); min-height: 14px;" class=""><span
              style="font-variant-ligatures: no-common-ligatures"
              class=""></span><br class="">
          </div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">#-----testresult-----</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">compileJDK=/Library/Java/JavaVirtualMachines/jdk1.8.0_111.jdk/Contents/Home</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">description=file\:/opt/buildAgent/work/9d35cf148e807375/test/java/awt/Focus/AutoRequestFocusTest/AutoRequestFocusSetVisibleTest.java\#id0</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">elapsed=7463 0\:00\:07.463</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">end=Mon May 29 18\:56\:12
              MSK 2017</span></div>
          <div style="margin: 0px; line-height: normal; font-family:
            Menlo; color: rgb(40, 254, 20); background-color: rgba(0, 0,
            0, 0.901961);" class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">environment=regtest</span></div>
          <div class=""><span style="font-variant-ligatures:
              no-common-ligatures" class="">
              <div class="">===================================8<——————————————————————————————</div>
            </span></div>
          <div class=""><br class="">
          </div>
          <div class="">And jtreg output:</div>
          <span class=""><font class="" face="Courier">runner starting
              test:
java/awt/Focus/AutoRequestFocusTest/AutoRequestFocusSetVisibleTest.java#id0<br
                class="">
              runner finished test:
java/awt/Focus/AutoRequestFocusTest/AutoRequestFocusSetVisibleTest.java#id0<br
                class="">
              Failed. Execution failed: `main' threw exception:
              TestFailedException: Test failed: the window shouldn't
              gain focus but it did!</font><br class="">
            <br class="">
          </span><span class="">As you can see the test </span><i
            class="">java/awt/Focus/AutoRequestFocusTest/AutoRequestFocusSetVisibleTest.java
          </i>became <i class="">java/awt/Focus/AutoRequestFocusTest/AutoRequestFocusSetVisibleTest.java\#id0</i> ("<i
            class="">\#id0</i>” was added).</div>
        <div class="">Please note the issue was observed intermittently.</div>
        <div class=""><br class="">
        </div>
        <div class="">The matter was that this test was included into my
          exclude list, nevertheless it was executed because of this
          postfix (most probably new test name does not correspond to
          the name included into exclude list).</div>
        <div class="">I looked through documentation on jtreg but could
          not find any explanations for this behaviour.</div>
        <div class="">My suspicious was concurrent execution of the
          tests but I could not find any symptoms confirming that.</div>
        <div class=""><br class="">
        </div>
        <div class="">My original intentions was to exclude some tests
          from test runs but I could not do it because of this issue. I
          tried to use regular expressions in test names adding them
          into exclude list but it did not help.</div>
        <div class=""><br class="">
        </div>
        <div class="">
          <div class="">Here is command line used to start test runs:</div>
          <div class=""><br class="">
            <font class="" face="Courier">$
              jtreg -exclude:test/jbProblemsList.txt -ignore:quiet -v -a
              -xml -compilejdk:'%env.JDK_18_x64%'
              -testjdk:'%jtreg.testjdk%' -timeoutFactor:2 test/java/awt
              || echo 'Execution complete’</font></div>
          <div class=""><br class="">
          </div>
        </div>
        <div class="">Could you please help me in resolving the
          following questions? why does jtreg add some postfixes? how
          can I exclude such tests from test runs?</div>
        <div class=""><br class="">
        </div>
        <div class=""><br class="">
        </div>
        <div class="">Thanks in advance, </div>
        <div class="">Vitaly</div>
        <div class=""><br class="">
        </div>
      </div>
    </blockquote>
    <br>
  </body>
</html>