Skip to content

Commit

Permalink
Oracle proxy authentication test fix
Browse files Browse the repository at this point in the history
Remove too strong dependency on Oracle error message. There is change between Oracle 23c and Oracle 23ai.

Signed-off-by: Radek Felcman <[email protected]>
  • Loading branch information
rfelcman committed May 16, 2024
1 parent b5d6f9a commit 852cd97
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ public void testCreateWithOutProxy() throws Exception{
empId = employee.getId();
commitTransaction(em);
} catch (Exception ex) {
if (ex.getMessage().indexOf("ORA-00942: table or view does not exist") == -1){
if (!(ex.getMessage().contains("java.sql.SQLSyntaxErrorException") && ex.getMessage().contains("ORA-00942"))) {
ex.printStackTrace();
fail("it's not the right exception");
}
Expand Down Expand Up @@ -363,7 +363,7 @@ public void testFlushRollback() throws Exception{
em.persist(employee);
em.flush();
} catch (Exception ex) {
if (ex.getMessage().indexOf("ORA-00942: table or view does not exist") == -1){
if (!(ex.getMessage().contains("java.sql.SQLSyntaxErrorException") && ex.getMessage().contains("ORA-00942"))) {
ex.printStackTrace();
fail("it's not the right exception");
}
Expand Down

0 comments on commit 852cd97

Please sign in to comment.