ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/test/tck/JSR166TestCase.java
(Generate patch)

Comparing jsr166/src/test/tck/JSR166TestCase.java (file contents):
Revision 1.235 by jsr166, Sat Jul 22 18:23:59 2017 UTC vs.
Revision 1.238 by jsr166, Mon Dec 11 00:27:08 2017 UTC

# Line 445 | Line 445 | public class JSR166TestCase extends Test
445          }
446      }
447  
448 <    public static boolean atLeastJava6() { return JAVA_CLASS_VERSION >= 50.0; }
449 <    public static boolean atLeastJava7() { return JAVA_CLASS_VERSION >= 51.0; }
450 <    public static boolean atLeastJava8() { return JAVA_CLASS_VERSION >= 52.0; }
451 <    public static boolean atLeastJava9() {
452 <        return JAVA_CLASS_VERSION >= 53.0
453 <            // As of 2015-09, java9 still uses 52.0 class file version
454 <            || JAVA_SPECIFICATION_VERSION.matches("^(1\\.)?(9|[0-9][0-9])$");
455 <    }
456 <    public static boolean atLeastJava10() {
457 <        return JAVA_CLASS_VERSION >= 54.0
458 <            || JAVA_SPECIFICATION_VERSION.matches("^(1\\.)?[0-9][0-9]$");
459 <    }
448 >    public static boolean atLeastJava6()  { return JAVA_CLASS_VERSION >= 50.0; }
449 >    public static boolean atLeastJava7()  { return JAVA_CLASS_VERSION >= 51.0; }
450 >    public static boolean atLeastJava8()  { return JAVA_CLASS_VERSION >= 52.0; }
451 >    public static boolean atLeastJava9()  { return JAVA_CLASS_VERSION >= 53.0; }
452 >    public static boolean atLeastJava10() { return JAVA_CLASS_VERSION >= 54.0; }
453  
454      /**
455       * Collects all JSR166 unit tests as one suite.
# Line 544 | Line 537 | public class JSR166TestCase extends Test
537                  "DoubleAdderTest",
538                  "ForkJoinPool8Test",
539                  "ForkJoinTask8Test",
540 +                "HashMapTest",
541                  "LinkedBlockingDeque8Test",
542                  "LinkedBlockingQueue8Test",
543                  "LongAccumulatorTest",
# Line 1913 | Line 1907 | public class JSR166TestCase extends Test
1907          Collections.shuffle(Arrays.asList(array), ThreadLocalRandom.current());
1908      }
1909  
1910 +    /**
1911 +     * Returns the same String as would be returned by {@link
1912 +     * Object#toString}, whether or not the given object's class
1913 +     * overrides toString().
1914 +     *
1915 +     * @see System#identityHashCode
1916 +     */
1917 +    static String identityString(Object x) {
1918 +        return x.getClass().getName()
1919 +            + "@" + Integer.toHexString(System.identityHashCode(x));
1920 +    }
1921 +
1922      // --- Shared assertions for Executor tests ---
1923  
1924      /**

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines