From 9323ded25eb19fb1d5fcaaee9d24eb407836e815 Mon Sep 17 00:00:00 2001 From: Ajay Paul Date: Wed, 3 Jul 2024 18:07:07 +0530 Subject: [PATCH] review comments updated --- .../testing/tests/jpa/plsql/PLSQLTestSuite.java | 16 ++++++++++++---- pom.xml | 2 +- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/jpa/eclipselink.jpa.test/src/it/java/org/eclipse/persistence/testing/tests/jpa/plsql/PLSQLTestSuite.java b/jpa/eclipselink.jpa.test/src/it/java/org/eclipse/persistence/testing/tests/jpa/plsql/PLSQLTestSuite.java index 87d1fcc48ec..d058ebfdde1 100644 --- a/jpa/eclipselink.jpa.test/src/it/java/org/eclipse/persistence/testing/tests/jpa/plsql/PLSQLTestSuite.java +++ b/jpa/eclipselink.jpa.test/src/it/java/org/eclipse/persistence/testing/tests/jpa/plsql/PLSQLTestSuite.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2020 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2024 Oracle and/or its affiliates. All rights reserved. * * This program and the accompanying materials are made available under the * terms of the Eclipse Public License v. 2.0 which is available at @@ -25,6 +25,7 @@ import org.eclipse.persistence.internal.databaseaccess.DatabaseCall; import org.eclipse.persistence.internal.helper.DatabaseType; +import org.eclipse.persistence.internal.helper.Helper; import org.eclipse.persistence.internal.jpa.EJBQueryImpl; import org.eclipse.persistence.platform.database.oracle.annotations.OracleArray; import org.eclipse.persistence.platform.database.oracle.jdbc.OracleArrayType; @@ -329,9 +330,16 @@ public void testSimpleFunction() { query.setParameter("P_POSITIVEN", 1); query.setParameter("P_SIGNTYPE", 1); query.setParameter("P_NUMBER", 1); - int result = (Integer)query.getSingleResult(); - if (result != 1) { - fail("Incorrect result."); + if (getPlatform().isOracle23() && Helper.compareVersions(getPlatform().getDriverVersion(), "23.0.0") >= 0) { + boolean result = (Boolean) query.getSingleResult(); + if (!result) { + fail("Incorrect result."); + } + } else { + int result = (Integer) query.getSingleResult(); + if (result != 1) { + fail("Incorrect result."); + } } } finally { closeEntityManagerAndTransaction(em); diff --git a/pom.xml b/pom.xml index 47152fc6378..d72f4de9f03 100644 --- a/pom.xml +++ b/pom.xml @@ -219,7 +219,7 @@ 42.2.18 1.3.0-alpha5 - 23.2.0.0 + 23.4.0.24.05 19.3.0.0 12.2.1-2-0