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

[lworld] UnifiedPrimitiveClassNestHostTest.java should test with the primary mirror

XMLWordPrintable

      test/langtools/tools/javac/valhalla/lworld-values/UnifiedPrimitiveClassNestHostTest.java fails because it verifies the nest host with a secondary mirror but the core reflection API returns the primary mirror.

      It's a test bug.

      diff --git a/test/langtools/tools/javac/valhalla/lworld-values/UnifiedPrimitiveClassNestHostTest.java b/test/langtools/tools/javac/valhalla/lworld-values/UnifiedPrimitiveClassNestHostTest.java
      index 7ff37eccdb6..59c1b84b6a3 100644
      --- a/test/langtools/tools/javac/valhalla/lworld-values/UnifiedPrimitiveClassNestHostTest.java
      +++ b/test/langtools/tools/javac/valhalla/lworld-values/UnifiedPrimitiveClassNestHostTest.java
      @@ -65,7 +65,7 @@ public primitive class UnifiedPrimitiveClassNestHostTest implements java.io.Seri
               if (!members[0].equals(nestHost))
                   throw new AssertionError("Wrong initial member: " + members[0]);
       
      - if (!members[1].equals(Inner.class))
      + if (!members[1].equals(Inner.class.asPrimaryType()))
                   throw new AssertionError("Wrong initial member: " + members[1]);
       
               if (!members[1].getNestHost().equals(nestHost))

            mchung Mandy Chung (Inactive)
            mchung Mandy Chung (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: