Project:Perl/maint-notes/dev-perl/DBD-MariaDB
From Gentoo Wiki
Jump to:navigation
Jump to:search
Testing
Performing tests with this package requires a manual installation of either:
- dev-db/mariadb (preferred)
- dev-db/mysql
First, make sure the server is running via relevant rc/init
calls, and then ensure the relevant permissions and tables are configured.
CREATE USER 'test'@'localhost' IDENTIFIED BY 'test';
CREATE DATABASE test;
GRANT ALL PRIVILEGES ON test.* TO 'test'@'localhost';
Once this is done, emerge the usual way, and your test output should look a lot like this:
* Test::Harness Jobs=3
make -j3 --load-average=4 test TEST_VERBOSE=0
"/usr/bin/perl" -MExtUtils::Command::MM -e 'cp_nonempty' -- MariaDB.bs blib/arch/auto/DBD/MariaDB/MariaDB.bs 644
PERL_DL_NONLAZY=1 "/usr/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00base.t .............................. 1/7 # DBI version is 1.637
# Driver version is 1.21
t/00base.t .............................. ok
# Connected to 'test' database on 'DBI:MariaDB:test:localhost;mariadb_connect_timeout=120;mariadb_read_timeout=120;mariadb_write_timeout=120' server
# Database 'test' has charset 'utf8mb4'
# Database 'test' has collation 'utf8mb4_unicode_ci'
t/05dbcreate.t .......................... ok
t/10connect.t ........................... 1/? # mariadb_clientinfo is: 10.4.3
# mariadb_clientversion is: 100403
# mariadb_serverversion is: 100413
# mariadb_hostinfo is: Localhost via UNIX socket
# mariadb_serverinfo is: 10.4.13-MariaDB-log
# mariadb_stat is: Uptime: 461 Threads: 8 Questions: 3497 Slow queries: 0 Opens: 190 Flush tables: 1 Open tables: 15 Queries per second avg: 7.585
# mariadb_protoinfo is: 10
# SQL_DBMS_NAME is MariaDB
# SQL_DBMS_VER is 10.04.1300
# SQL_SERVER_NAME is Localhost via UNIX socket
# SQL_DRIVER_VER is 01.21.0000
# Default storage engine is: InnoDB
# @@character_set_client is: utf8mb4
# @@character_set_connection is: utf8mb4
# @@character_set_database is: utf8mb4
# @@character_set_results is: utf8mb4
# @@character_set_server is: utf8mb4
# @@collation_connection is: utf8mb4_unicode_ci
# @@collation_database is: utf8mb4_unicode_ci
# @@collation_server is: utf8mb4_unicode_ci
# auto_reconnects_failed is: 0
# auto_reconnects_ok is: 0
t/10connect.t ........................... ok
t/60leaks.t ............................. skipped: Skip $ENV{EXTENDED_TESTING} is not set
t/rt75353-innodb-lock-timeout.t ......... ok
t/11data_sources.t ...................... ok
t/12embedded.t .......................... skipped: Connection error: Embedded server is not supported
t/13disconnect.t ........................ ok
t/14destruct.t .......................... ok
t/15reconnect.t ......................... ok
t/16dbi-get_info.t ...................... ok
t/20createdrop.t ........................ ok
t/25lockunlock.t ........................ ok
t/29warnings.t .......................... ok
t/30insertfetch.t ....................... ok
t/31insertid.t .......................... ok
t/32insert_error.t ...................... ok
t/35limit.t ............................. ok
t/35prepare.t ........................... ok
t/40bindparam.t ......................... ok
t/40bindparam2.t ........................ ok
t/40bit.t ............................... ok
t/40blobs.t ............................. ok
t/40catalog.t ........................... ok
t/40invalid_attributes.t ................ ok
t/40keyinfo.t ........................... ok
t/40listfields.t ........................ ok
t/40nulls.t ............................. ok
t/rt85919-fetch-lost-connection.t ....... ok
t/40nulls_prepare.t ..................... ok
t/40numrows.t ........................... ok
t/40server_prepare.t .................... ok
t/40server_prepare_error.t .............. ok
t/40sth_attr.t .......................... ok
t/40server_prepare_crash.t .............. ok
t/41bindparam.t ......................... ok
t/40types.t ............................. ok
t/41blobs_prepare.t ..................... ok
t/42bindparam.t ......................... ok
t/41int_min_max.t ....................... ok
t/43count_params.t ...................... ok
t/44call_placeholder.t .................. ok
t/44limit_placeholder.t ................. ok
t/45bind_no_backslash_escapes.t ......... ok
t/50commit.t ............................ ok
t/50chopblanks.t ........................ ok
t/52comment.t ........................... ok
t/51bind_type_guessing.t ................ ok
t/53comment.t ........................... ok
t/55unicode.t ........................... ok
t/55utf8.t .............................. ok
t/55utf8_jp.t ........................... ok
t/56connattr.t .......................... skipped: performance schema not enabled
t/55utf8mb4.t ........................... ok
t/65types.t ............................. ok
t/70takeimp.t ........................... ok
t/71impdata.t ........................... ok
t/75supported_sql.t ..................... ok
t/76multi_statement.t ................... ok
t/77max_allowed_packet.t ................ ok
t/65segfault.t .......................... ok
t/80procs.t ............................. ok
t/81procs.t ............................. ok
t/85init_command.t ...................... ok
t/86_bug_36972.t ........................ ok
t/88async-multi-stmts.t ................. ok
t/89async-method-check.t ................ ok
t/90utf8_params.t ....................... ok
t/91errcheck.t .......................... ok
t/92ssl_backronym_vulnerability.t ....... ok
t/92ssl_connection.t .................... skipped: Server does not support SSL connections
t/92ssl_optional.t ...................... ok
t/92ssl_riddle_vulnerability.t .......... ok
t/93net_ssleay.t ........................ ok
t/99_bug_server_prepare_blob_null.t ..... ok
t/cve-2017-3302.t ....................... ok
t/magic.t ............................... ok
t/rt110983-valid-mysqlfd.t .............. ok
t/rt118977-zerofill.t ................... ok
t/rt122541-decimals.t ................... ok
t/rt25389-bin-case.t .................... ok
t/rt50304-column_info_parentheses.t ..... ok
t/rt61849-bind-param-buffer-overflow.t .. ok
t/rt83494-quotes-comments.t ............. ok
t/rt86153-reconnect-fail-memory.t ....... skipped: $ENV{EXTENDED_TESTING} is not set
t/rt88006-bit-prepare.t ................. ok
t/rt91715.t ............................. ok
t/87async.t ............................. ok
All tests successful.
Files=88, Tests=3590, 17 wallclock secs ( 0.83 usr 0.27 sys + 13.83 cusr 3.63 csys = 18.56 CPU)
Result: PASS