test/jdk/java/util/concurrent/tck/JSR166TestCase.java
changeset 48541 946e34c2dec9
parent 47306 90b7465b9ac7
child 48843 21efc1774302
equal deleted inserted replaced
48540:221cf8307606 48541:946e34c2dec9
   470         } catch (Throwable t) {
   470         } catch (Throwable t) {
   471             throw new Error(t);
   471             throw new Error(t);
   472         }
   472         }
   473     }
   473     }
   474 
   474 
   475     public static boolean atLeastJava6() { return JAVA_CLASS_VERSION >= 50.0; }
   475     public static boolean atLeastJava6()  { return JAVA_CLASS_VERSION >= 50.0; }
   476     public static boolean atLeastJava7() { return JAVA_CLASS_VERSION >= 51.0; }
   476     public static boolean atLeastJava7()  { return JAVA_CLASS_VERSION >= 51.0; }
   477     public static boolean atLeastJava8() { return JAVA_CLASS_VERSION >= 52.0; }
   477     public static boolean atLeastJava8()  { return JAVA_CLASS_VERSION >= 52.0; }
   478     public static boolean atLeastJava9() {
   478     public static boolean atLeastJava9()  { return JAVA_CLASS_VERSION >= 53.0; }
   479         return JAVA_CLASS_VERSION >= 53.0
   479     public static boolean atLeastJava10() { return JAVA_CLASS_VERSION >= 54.0; }
   480             // As of 2015-09, java9 still uses 52.0 class file version
       
   481             || JAVA_SPECIFICATION_VERSION.matches("^(1\\.)?(9|[0-9][0-9])$");
       
   482     }
       
   483     public static boolean atLeastJava10() {
       
   484         return JAVA_CLASS_VERSION >= 54.0
       
   485             || JAVA_SPECIFICATION_VERSION.matches("^(1\\.)?[0-9][0-9]$");
       
   486     }
       
   487 
   480 
   488     /**
   481     /**
   489      * Collects all JSR166 unit tests as one suite.
   482      * Collects all JSR166 unit tests as one suite.
   490      */
   483      */
   491     public static Test suite() {
   484     public static Test suite() {