From ae8b4f84aa839e88c0dbc7409bc82d492224eec8 Mon Sep 17 00:00:00 2001 From: Anthony Tuininga Date: Fri, 2 Nov 2018 15:45:09 -0600 Subject: [PATCH] Entries can remain in v$sql_monitor for a period of time so only look at the executing one. --- test/Connection.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/Connection.py b/test/Connection.py index 163a7c3..62a2501 100644 --- a/test/Connection.py +++ b/test/Connection.py @@ -77,7 +77,8 @@ class TestConnection(TestCase): if CLIENT_VERSION >= (12, 1): self.__VerifyAttributes(connection, "dbop", "cx_OracleTest_DBOP", "select dbop_name from v$sql_monitor " - "where sid = sys_context('userenv', 'sid')") + "where sid = sys_context('userenv', 'sid')" + "and status = 'EXECUTING'") self.__VerifyAttributes(connection, "action", "cx_OracleTest_Action", "select sys_context('userenv', 'action') from dual") self.__VerifyAttributes(connection, "module", "cx_OracleTest_Module",