This is an automated email from the ASF dual-hosted git repository.

fjtiradosarti pushed a commit to branch main
in repository 
https://gitbox.apache.org/repos/asf/incubator-kie-kogito-runtimes.git


The following commit(s) were added to refs/heads/main by this push:
     new 7a42795606 [Fix_@818] Fixing native python test on Java 17 (#3349)
7a42795606 is described below

commit 7a4279560634e5b2138df4f6ee90163c3094a0a2
Author: Francisco Javier Tirado Sarti 
<[email protected]>
AuthorDate: Mon Jan 15 18:02:40 2024 +0100

    [Fix_@818] Fixing native python test on Java 17 (#3349)
---
 quarkus/addons/python/integration-tests/pom.xml                  | 2 +-
 .../test/java/org/kie/kogito/quarkus/workflows/PythonFlowIT.java | 4 ----
 .../src/main/resources/META-INF/native-image/jni-config.json     | 9 +++++++++
 3 files changed, 10 insertions(+), 5 deletions(-)

diff --git a/quarkus/addons/python/integration-tests/pom.xml 
b/quarkus/addons/python/integration-tests/pom.xml
index c077d2d912..f5f387151a 100644
--- a/quarkus/addons/python/integration-tests/pom.xml
+++ b/quarkus/addons/python/integration-tests/pom.xml
@@ -152,7 +152,7 @@
             <artifactId>maven-failsafe-plugin</artifactId>
             <configuration>
              <environmentVariables>
-               <LD_LIBRARY_PATH>${env.JAVA_HOME}/lib/server</LD_LIBRARY_PATH>
+               
<LD_LIBRARY_PATH>${env.JAVA_HOME}/lib/server;${env.GRAALVM_HOME}/lib/server</LD_LIBRARY_PATH>
              </environmentVariables>
             </configuration>
           </plugin>
diff --git 
a/quarkus/addons/python/integration-tests/src/test/java/org/kie/kogito/quarkus/workflows/PythonFlowIT.java
 
b/quarkus/addons/python/integration-tests/src/test/java/org/kie/kogito/quarkus/workflows/PythonFlowIT.java
index 23d331775f..75de1ed8b7 100644
--- 
a/quarkus/addons/python/integration-tests/src/test/java/org/kie/kogito/quarkus/workflows/PythonFlowIT.java
+++ 
b/quarkus/addons/python/integration-tests/src/test/java/org/kie/kogito/quarkus/workflows/PythonFlowIT.java
@@ -20,7 +20,6 @@ package org.kie.kogito.quarkus.workflows;
 
 import org.junit.jupiter.api.Test;
 
-import io.quarkus.test.junit.DisabledOnIntegrationTest;
 import io.quarkus.test.junit.QuarkusIntegrationTest;
 import io.restassured.http.ContentType;
 
@@ -28,9 +27,6 @@ import static io.restassured.RestAssured.given;
 import static org.hamcrest.CoreMatchers.is;
 
 @QuarkusIntegrationTest
-@DisabledOnIntegrationTest(
-        value = "Temporarily disabling test since python cannot be properly 
initialized inside the native image",
-        forArtifactTypes = 
DisabledOnIntegrationTest.ArtifactType.NATIVE_BINARY)
 class PythonFlowIT {
 
     @Test
diff --git 
a/quarkus/addons/python/runtime/src/main/resources/META-INF/native-image/jni-config.json
 
b/quarkus/addons/python/runtime/src/main/resources/META-INF/native-image/jni-config.json
index 6ed2a8dc04..6814b8c68c 100644
--- 
a/quarkus/addons/python/runtime/src/main/resources/META-INF/native-image/jni-config.json
+++ 
b/quarkus/addons/python/runtime/src/main/resources/META-INF/native-image/jni-config.json
@@ -29,6 +29,7 @@
   {
     "name": "java.util.Map$Entry[]"
   },
+  {"name":"java.lang.reflect.AnnotatedElement", "allPublicMethods": true},
   {"name":"java.lang.IllegalStateException","allPublicMethods":true},
   
{"name":"java.lang.NoSuchMethodError","allPublicMethods":true,"allPublicConstructors":true,
 "allPublicClasses": true},
   {"name":"java.lang.IllegalStateException[]","allPublicMethods":true},
@@ -237,6 +238,10 @@
   {
     "name": "jep.MainInterpreter"
   },
+  {
+       "name": "jep.PyMethod",
+       "allPublicMethods": true
+  },
   {
     "name": "jep.NDArray",
     "allPublicMethods": true,
@@ -245,5 +250,9 @@
   {
     "name": "jep.ClassList",
     "allPublicMethods": true
+  },
+  {
+       "name": "java.lang.reflect.Executable",
+       "allPublicMethods": true
   }
 ]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to