psql: Fix test
authorPeter Eisentraut <[email protected]>
Tue, 12 Oct 2021 16:22:15 +0000 (18:22 +0200)
committerPeter Eisentraut <[email protected]>
Tue, 12 Oct 2021 16:22:15 +0000 (18:22 +0200)
The test didn't work on platforms where getopt() doesn't support
non-option arguments before options.

src/bin/psql/t/001_basic.pl

index c6d01c0abf061e4f780e1486749a7a3318be58f7..685744744a9767a24f13ab4fdbc120c4c286d474 100644 (file)
@@ -40,5 +40,5 @@ $node->command_like([ 'psql', '-c', '\help SELECT' ], qr/SELECT/, '\help');
 
 
 # Test clean handling of unsupported replication command responses
-$node->command_fails_like([ 'psql', 'replication=database', '-c', 'START_REPLICATION 0/0' ],
+$node->command_fails_like([ 'psql', '-d', 'replication=database', '-c', 'START_REPLICATION 0/0' ],
        qr/^unexpected PQresultStatus: 8$/, 'handling of unexpected PQresultStatus');