mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-14 10:27:04 +08:00
They turned out to be too much of a portability headache, because they need a fairly new version of Test::More to work properly.
25 lines
585 B
Perl
25 lines
585 B
Perl
use strict;
|
|
use warnings;
|
|
use TestLib;
|
|
use Test::More tests => 14;
|
|
|
|
program_help_ok('createlang');
|
|
program_version_ok('createlang');
|
|
program_options_handling_ok('createlang');
|
|
|
|
my $tempdir = tempdir;
|
|
start_test_server $tempdir;
|
|
|
|
command_fails(
|
|
[ 'createlang', 'plpgsql', 'postgres' ],
|
|
'fails if language already exists');
|
|
|
|
psql 'postgres', 'DROP EXTENSION plpgsql';
|
|
issues_sql_like(
|
|
[ 'createlang', 'plpgsql', 'postgres' ],
|
|
qr/statement: CREATE EXTENSION "plpgsql"/,
|
|
'SQL CREATE EXTENSION run');
|
|
|
|
command_like([ 'createlang', '--list', 'postgres' ],
|
|
qr/plpgsql/, 'list output');
|