X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=tests%2Fcancel001.phpt;h=8ca8793e8043184485ade748d0fa3d2baf6ae995;hb=be621b64a9a5faea34741430db84cfe16b7b40b6;hp=f374f666c5888696c9a3cfbbb7560ce69c4f8f80;hpb=86138e39ba4bfc44b3eb1c4eaa3dccabcc3cea53;p=m6w6%2Fext-pq diff --git a/tests/cancel001.phpt b/tests/cancel001.phpt index f374f66..8ca8793 100644 --- a/tests/cancel001.phpt +++ b/tests/cancel001.phpt @@ -16,18 +16,58 @@ $c->execAsync("SELECT pg_sleep(2)"); $x->cancel(); +var_dump($c === $x->connection); var_dump($c->getResult()); - +printf("%s\n", $c->errorMessage); ?> DONE --EXPECTF-- Test -object(pq\Result)#%d (6) { +bool(true) +object(pq\Result)#%d (9) { ["status"]=> int(7) + ["statusMessage"]=> + string(11) "FATAL_ERROR" ["errorMessage"]=> - string(48) "ERROR: canceling statement due to user request -" + string(47) "ERROR: canceling statement due to user request" + ["diag"]=> + array(17) { + ["severity"]=> + string(5) "ERROR" + ["sqlstate"]=> + string(5) "57014" + ["message_primary"]=> + string(39) "canceling statement due to user request" + ["message_detail"]=> + NULL + ["message_hint"]=> + NULL + ["statement_position"]=> + NULL + ["internal_position"]=> + NULL + ["internal_query"]=> + NULL + ["context"]=> + NULL + ["schema_name"]=> + NULL + ["table_name"]=> + NULL + ["column_name"]=> + NULL + ["datatype_name"]=> + NULL + ["constraint_name"]=> + NULL + ["source_file"]=> + string(10) "postgres.c" + ["source_line"]=> + string(4) "%d" + ["source_function"]=> + string(17) "ProcessInterrupts" + } ["numRows"]=> int(0) ["numCols"]=> @@ -36,5 +76,8 @@ object(pq\Result)#%d (6) { int(0) ["fetchType"]=> int(0) + ["autoConvert"]=> + int(65535) } +ERROR: canceling statement due to user request DONE