pgsql: test_json_parser: Fix broken file ref and inverted result check

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: test_json_parser: Fix broken file ref and inverted result check
Date: 2026-08-18 13:47:29
Message-ID: E1wwKA4-000000014He-09iq@gemulon.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers

test_json_parser: Fix broken file ref and inverted result check

A comma following a file ref in a perl print statement makes the
statement just print the file's GLOB rather than redirecting the
following arguments to the file. This meant the test was not testing any
contents and the logs were instead bulked up with what the test was
supposed to be testing.

Also, run_log() returns 1 for success, not 0, so the tests for the
return values were wrong. (We were getting 0 because of the comma error
above.)

Backpatch-thru: 17

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/195e8e427c07cc87ed8c8e819617bc87871893e5

Modified Files
--------------
src/test/modules/test_json_parser/t/004_test_parser_perf.pl | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Bruce Momjian 2026-08-18 14:43:54 pgsql: doc PG 19: update to current
Previous Message Peter Eisentraut 2026-08-18 12:19:09 pgsql: Message style fixes