You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by ja...@apache.org on 2020/11/21 13:46:05 UTC
[ant] branch master updated: Skip scriptdef-test.xml antunit tests
for JDK >=15 due to unavailability of script engine for "javascript"
language in JRE
This is an automated email from the ASF dual-hosted git repository.
jaikiran pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ant.git
The following commit(s) were added to refs/heads/master by this push:
new 458fba1 Skip scriptdef-test.xml antunit tests for JDK >=15 due to unavailability of script engine for "javascript" language in JRE
458fba1 is described below
commit 458fba12de0ff031017f116e9282f5ed626c7c5a
Author: Jaikiran Pai <ja...@apache.org>
AuthorDate: Sat Nov 21 19:15:44 2020 +0530
Skip scriptdef-test.xml antunit tests for JDK >=15 due to unavailability of script engine for "javascript" language in JRE
---
.../taskdefs/optional/script/scriptdef-test.xml | 18 +++++++++++-------
1 file changed, 11 insertions(+), 7 deletions(-)
diff --git a/src/tests/antunit/taskdefs/optional/script/scriptdef-test.xml b/src/tests/antunit/taskdefs/optional/script/scriptdef-test.xml
index b604aa2..e2a7718 100644
--- a/src/tests/antunit/taskdefs/optional/script/scriptdef-test.xml
+++ b/src/tests/antunit/taskdefs/optional/script/scriptdef-test.xml
@@ -26,13 +26,17 @@
</description>
<condition property="prereqs-ok">
- <or>
- <and>
- <available classname="org.apache.bsf.BSFManager" />
- <available classname="org.apache.bsf.engines.javascript.JavaScriptEngine" />
- </and>
- <available classname="javax.script.ScriptEngineManager" />
- </or>
+ <and>
+ <!-- Starting Java 15, there's no "javascript" script engine (not even nashorn) bundled in JRE -->
+ <javaversion atmost="14"/>
+ <or>
+ <and>
+ <available classname="org.apache.bsf.BSFManager" />
+ <available classname="org.apache.bsf.engines.javascript.JavaScriptEngine" />
+ </and>
+ <available classname="javax.script.ScriptEngineManager" />
+ </or>
+ </and>
</condition>
<!-- auto doesn't verify the language is supported and selects BSF