Skip to content

Commit 869a48a

Browse files
committed
fix: do not print the message twice in sqlite test verbose
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
1 parent ed73c90 commit 869a48a

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

Lib/test/test_sqlite3/__init__.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,9 @@
77
import sqlite3
88

99
# Implement the unittest "load tests" protocol.
10-
def load_tests(*args):
11-
if verbose:
10+
def load_tests(loader, tests, pattern):
11+
# Only print on the top-level call
12+
if verbose and pattern is None:
1213
print(f"test_sqlite3: testing with SQLite version {sqlite3.sqlite_version}")
1314
pkg_dir = os.path.dirname(__file__)
14-
return load_package_tests(pkg_dir, *args)
15+
return load_package_tests(pkg_dir, loader, tests, pattern)

0 commit comments

Comments
 (0)