Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit549ec20

Browse files
Replace Test::More plans with done_testing
Rather than doing manual book keeping to plan the number of tests to runin each TAP suite, conclude each run with done_testing() summing up thethe number of tests that ran. This removes the need for maintaning andupdating the plan count at the expense of an accurate count of remainingduring the test suite runtime.This patch has been discussed a number of times, often in the context ofother patches which updates tests, so a larger number of discussions canbe found in the archives.Reviewed-by: Julien Rouhaud <rjuju123@gmail.com>Reviewed-by: Dagfinn Ilmari Mannsåker <ilmari@ilmari.org>Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us>Reviewed-by: Michael Paquier <michael@paquier.xyz>Reviewed-by: Kyotaro Horiguchi <horikyota.ntt@gmail.com>Discussion:https://postgr.es/m/DD399313-3D56-4666-8079-88949DAC870F@yesql.se
1 parent751b8d2 commit549ec20

File tree

139 files changed

+394
-303
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

139 files changed

+394
-303
lines changed

‎contrib/amcheck/t/001_verify_heapam.pl‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
use PostgreSQL::Test::Utils;
99

1010
use Fcntlqw(:seek);
11-
use Test::Moretests=> 272;
11+
use Test::More;
1212

1313
my ($node,$result);
1414

@@ -283,3 +283,5 @@ sub check_all_options_uncorrupted
283283
}
284284
}
285285
}
286+
287+
done_testing();

‎contrib/amcheck/t/002_cic.pl‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
use PostgreSQL::Test::Cluster;
1010
use PostgreSQL::Test::Utils;
1111

12-
use Test::Moretests=> 3;
12+
use Test::More;
1313

1414
my ($node,$result);
1515

‎contrib/amcheck/t/003_cic_2pc.pl‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
use PostgreSQL::Test::Cluster;
1010
use PostgreSQL::Test::Utils;
1111

12-
use Test::Moretests=> 5;
12+
use Test::More;
1313

1414
Test::More->builder->todo_start('filesystem bug')
1515
if PostgreSQL::Test::Utils::has_wal_read_bug;

‎contrib/auto_explain/t/001_auto_explain.pl‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
use PostgreSQL::Test::Cluster;
88
use PostgreSQL::Test::Utils;
9-
use Test::Moretests=> 4;
9+
use Test::More;
1010

1111
my$node = PostgreSQL::Test::Cluster->new('main');
1212
$node->init;
@@ -53,3 +53,5 @@
5353
$log_contents,
5454
qr/"Node Type": "Index Scan"[^}]*"Index Name": "pg_class_relname_nsp_index"/s,
5555
"index scan logged, json mode");
56+
57+
done_testing();

‎contrib/bloom/t/001_wal.pl‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
use warnings;
77
use PostgreSQL::Test::Cluster;
88
use PostgreSQL::Test::Utils;
9-
use Test::Moretests=> 31;
9+
use Test::More;
1010

1111
my$node_primary;
1212
my$node_standby;
@@ -80,3 +80,5 @@ sub test_index_replay
8080
);
8181
test_index_replay("insert$i");
8282
}
83+
84+
done_testing();

‎contrib/oid2name/t/001_basic.pl‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,13 @@
55
use warnings;
66

77
use PostgreSQL::Test::Utils;
8-
use Test::Moretests=> 8;
8+
use Test::More;
99

1010
#########################################
1111
# Basic checks
1212

1313
program_help_ok('oid2name');
1414
program_version_ok('oid2name');
1515
program_options_handling_ok('oid2name');
16+
17+
done_testing();

‎contrib/test_decoding/t/001_repl_stats.pl‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
use File::Pathqw(rmtree);
99
use PostgreSQL::Test::Cluster;
1010
use PostgreSQL::Test::Utils;
11-
use Test::Moretests=> 2;
11+
use Test::More;
1212

1313
# Test set-up
1414
my$node = PostgreSQL::Test::Cluster->new('test');
@@ -118,3 +118,5 @@ sub test_slot_stats
118118

119119
# shutdown
120120
$node->stop;
121+
122+
done_testing();

‎contrib/vacuumlo/t/001_basic.pl‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,10 @@
55
use warnings;
66

77
use PostgreSQL::Test::Utils;
8-
use Test::Moretests=> 8;
8+
use Test::More;
99

1010
program_help_ok('vacuumlo');
1111
program_version_ok('vacuumlo');
1212
program_options_handling_ok('vacuumlo');
13+
14+
done_testing();

‎src/bin/initdb/t/001_initdb.pl‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
use File::statqw{lstat};
1212
use PostgreSQL::Test::Cluster;
1313
use PostgreSQL::Test::Utils;
14-
use Test::Moretests=> 22;
14+
use Test::More;
1515

1616
my$tempdir = PostgreSQL::Test::Utils::tempdir;
1717
my$xlogdir ="$tempdir/pgxlog";
@@ -92,3 +92,5 @@
9292
ok(check_mode_recursive($datadir_group, 0750, 0640),
9393
'check PGDATA permissions');
9494
}
95+
96+
done_testing();

‎src/bin/pg_amcheck/t/001_basic.pl‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,10 @@
55
use warnings;
66

77
use PostgreSQL::Test::Utils;
8-
use Test::Moretests=> 8;
8+
use Test::More;
99

1010
program_help_ok('pg_amcheck');
1111
program_version_ok('pg_amcheck');
1212
program_options_handling_ok('pg_amcheck');
13+
14+
done_testing();

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp