mirror of
https://github.com/timescale/timescaledb.git
synced 2025-05-22 13:40:56 +08:00
Increase psql verbosity to see error line numbers in remote_connection test
This commit is contained in:
parent
2bc3efa44e
commit
fc5341c47b
@ -15,13 +15,13 @@ SET ROLE :ROLE_DEFAULT_PERM_USER;
|
|||||||
-- failing conditions
|
-- failing conditions
|
||||||
\set ON_ERROR_STOP 0
|
\set ON_ERROR_STOP 0
|
||||||
SELECT test.condition();
|
SELECT test.condition();
|
||||||
ERROR: TestFailure @ test_utils.c ts_test_utils_condition:30 | (true_value == false_value)
|
ERROR: TestFailure | (true_value == false_value)
|
||||||
SELECT test.int64_eq();
|
SELECT test.int64_eq();
|
||||||
ERROR: TestFailure @ test_utils.c ts_test_utils_int64_eq:40 | (big == small) [32532978 == 3242234]
|
ERROR: TestFailure | (big == small) [32532978 == 3242234]
|
||||||
SELECT test.ptr_eq();
|
SELECT test.ptr_eq();
|
||||||
ERROR: TestFailure @ test_utils.c ts_test_utils_ptr_eq:54 | (true_ptr == false_ptr)
|
ERROR: TestFailure | (true_ptr == false_ptr)
|
||||||
SELECT test.double_eq();
|
SELECT test.double_eq();
|
||||||
ERROR: TestFailure @ test_utils.c ts_test_utils_double_eq:65 | (big_double == small_double) [923423478.324200 == 324.300000]
|
ERROR: TestFailure | (big_double == small_double) [923423478.324200 == 324.300000]
|
||||||
\set ON_ERROR_STOP 1
|
\set ON_ERROR_STOP 1
|
||||||
-- Test debug points
|
-- Test debug points
|
||||||
--
|
--
|
||||||
|
@ -30,12 +30,7 @@ strip_path(const char *filename)
|
|||||||
#define TestFailure(fmt, ...) \
|
#define TestFailure(fmt, ...) \
|
||||||
do \
|
do \
|
||||||
{ \
|
{ \
|
||||||
elog(ERROR, \
|
elog(ERROR, "TestFailure | " fmt "", ##__VA_ARGS__); \
|
||||||
"TestFailure @ %s %s:%d | " fmt "", \
|
|
||||||
strip_path(__FILE__), \
|
|
||||||
__func__, \
|
|
||||||
__LINE__, \
|
|
||||||
##__VA_ARGS__); \
|
|
||||||
pg_unreachable(); \
|
pg_unreachable(); \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
@ -86,7 +81,7 @@ strip_path(const char *filename)
|
|||||||
MemoryContextSwitchTo(oldctx); \
|
MemoryContextSwitchTo(oldctx); \
|
||||||
if (!this_has_panicked) \
|
if (!this_has_panicked) \
|
||||||
{ \
|
{ \
|
||||||
elog(ERROR, "failed to panic @ line %d", __LINE__); \
|
elog(ERROR, "failed to panic"); \
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
|
@ -45,6 +45,7 @@ INSERT INTO "S 1"."T 1"
|
|||||||
-- ===================================================================
|
-- ===================================================================
|
||||||
-- run tests
|
-- run tests
|
||||||
-- ===================================================================
|
-- ===================================================================
|
||||||
|
\set VERBOSITY verbose
|
||||||
SELECT * FROM test.get_connection_stats();
|
SELECT * FROM test.get_connection_stats();
|
||||||
connections_created | connections_closed | results_created | results_cleared
|
connections_created | connections_closed | results_created | results_cleared
|
||||||
---------------------+--------------------+-----------------+-----------------
|
---------------------+--------------------+-----------------+-----------------
|
||||||
@ -53,7 +54,8 @@ SELECT * FROM test.get_connection_stats();
|
|||||||
|
|
||||||
\set ON_ERROR_STOP 0
|
\set ON_ERROR_STOP 0
|
||||||
SELECT test.send_remote_query_that_generates_exception();
|
SELECT test.send_remote_query_that_generates_exception();
|
||||||
ERROR: bad query error thrown from test
|
ERROR: XX000: bad query error thrown from test
|
||||||
|
LOCATION: ts_test_bad_remote_query, connection.c:184
|
||||||
\set ON_ERROR_STOP 1
|
\set ON_ERROR_STOP 1
|
||||||
SELECT * FROM test.get_connection_stats();
|
SELECT * FROM test.get_connection_stats();
|
||||||
connections_created | connections_closed | results_created | results_cleared
|
connections_created | connections_closed | results_created | results_cleared
|
||||||
|
@ -56,6 +56,7 @@ INSERT INTO "S 1"."T 1"
|
|||||||
-- run tests
|
-- run tests
|
||||||
-- ===================================================================
|
-- ===================================================================
|
||||||
|
|
||||||
|
\set VERBOSITY verbose
|
||||||
SELECT * FROM test.get_connection_stats();
|
SELECT * FROM test.get_connection_stats();
|
||||||
\set ON_ERROR_STOP 0
|
\set ON_ERROR_STOP 0
|
||||||
SELECT test.send_remote_query_that_generates_exception();
|
SELECT test.send_remote_query_that_generates_exception();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user