[jdk11u-dev] RFR: 8266254: Update to use jtreg 6

George Adams duke at openjdk.org
Thu Jul 21 08:34:45 UTC 2022


On Thu, 21 Jul 2022 07:35:25 GMT, Goetz Lindenmaier <goetz at openjdk.org> wrote:

>> Backport required in order to bump to jtreg 6
>
> Hi,
> our testing shows a row of problems with the change. Arno already spotted some of the fixes in head, thanks! In addition there is 
> test/nashorn/src/jdk/nashorn/api/scripting/test/ScriptObjectMirrorTest.java:285: error: reference to assertEquals is ambiguous
>         assertEquals(42.0, obj.to(Double.class));

@GoeLin I'd like to get your thoughts here but I assume I can fix that final error with this:


diff --git a/test/nashorn/src/jdk/nashorn/api/scripting/test/ScriptObjectMirrorTest.java b/test/nashorn/src/jdk/nashorn/api/scripting/test/ScriptObjectMirrorTest.java
index f43c0db2f6c..6b6d4b58b0c 100644
--- a/test/nashorn/src/jdk/nashorn/api/scripting/test/ScriptObjectMirrorTest.java
+++ b/test/nashorn/src/jdk/nashorn/api/scripting/test/ScriptObjectMirrorTest.java
@@ -282,7 +282,7 @@ public class ScriptObjectMirrorTest {
 
         ScriptObjectMirror obj = (ScriptObjectMirror)e.eval(
             "({ valueOf: function() { return 42 } })");
-        assertEquals(42.0, obj.to(Double.class));
+        assertEquals(new Double(42.0), obj.to(Double.class));
 
         obj = (ScriptObjectMirror)e.eval(
             "({ toString: function() { return 'foo' } })");

-------------

PR: https://git.openjdk.org/jdk11u-dev/pull/1241


More information about the jdk-updates-dev mailing list