]> granicus.if.org Git - postgresql/commitdiff
Avoid assuming that we know the spelling of getopt_long's error messages.
authorTom Lane <tgl@sss.pgh.pa.us>
Fri, 18 Jan 2019 00:31:03 +0000 (19:31 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Fri, 18 Jan 2019 00:31:28 +0000 (19:31 -0500)
I've had enough of "fixing" this test case.  Whatever value it has
is limited to verifying that pgbench fails for an unrecognized switch,
and we don't need to assume anything about what getopt_long prints in
order to do that.

Discussion: https://postgr.es/m/9427.1547701450@sss.pgh.pa.us

src/bin/pgbench/t/002_pgbench_no_server.pl

index e82d3cb2429ea5459088699df5c873e0121dc19d..e87c028659d02864be52917c2eda3dc9c65776b2 100644 (file)
@@ -62,7 +62,7 @@ my @options = (
        [
                'bad option',
                '-h home -p 5432 -U calvin -d --bad-option',
-               [ qr{(unrecognized|illegal) option}, qr{--help.*more information} ]
+               [qr{--help.*more information}]
        ],
        [
                'no file',