3 messages in com.mysql.lists.perlRe: DBD::mysql t/dbdadmin test failur...| Subject: | Re: DBD::mysql t/dbdadmin test failure 7, 11, 15![]() |
|---|---|
| From: | Leif W (warp...@usa.net) |
| Date: | 08/10/2003 04:24:43 AM |
| List: | com.mysql.lists.perl |
Hello,
I'm not too familiar with the debugger, and I wasn't sure what to look for. I modified InDsnList to print out some more data, and modified one other Test error message (about the New DB not in DSN list). The output from make test ... is showing that InDsnList is being called, but the @dsnList is always empty, as nothing is being printed from inside the foreach loop.
sub InDsnList($@) { my($dsn, @dsnList) = @_; my($d); print "InDsnList called\n"; # for debugging foreach $d (@dsnList) { print "DSN: $d\n"; # for debugging if ($d =~ /^dbi:[^:]+:$dsn\b/i) { return 1; } } 0; }
...
Test($state or $accessDenied or InDsnList($testdsn, DBI->data_sources($mdriver)) or InDsnList($testdsn, DBI->data_sources($mdriver, {"host" => $test_host, "port" => $test_port}))) or print STDERR ("New DB $testdsn not in DSN list\n"); # added $testdsn to be more specific
defiant:~/.cpan/build/DBD-mysql-2.9002# make test TEST_FILES=t/dbdadmin.t TEST_VERBOSE=1 PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(1, 'blib/lib', 'blib/arch')" t/dbdadmin.t t/dbdadmin....mysql 1..21 ok 1 ok 2 ok 3 ok 4 ok 5 InDsnList called InDsnList called InDsnList called ok 6 InDsnList called InDsnList called not ok 7 New DB testaa not in DSN list ok 8 InDsnList called InDsnList called ok 9 ok 10 InDsnList called InDsnList called not ok 11 DSN testab not in DSN list. ok 12 InDsnList called InDsnList called ok 13 ok 14 InDsnList called InDsnList called not ok 15 DSN testac not in DSN list. ok 16 InDsnList called InDsnList called ok 17 ok 18 ok 19 ok 20 ok 21 FAILED tests 7, 11, 15 Failed 3/21 tests, 85.71% okay Failed Test Stat Wstat Total Fail Failed List of Failed
----------------------------------------------------------------------------
--- t/dbdadmin.t 21 3 14.29% 7 11 15 Failed 1/1 test scripts, 0.00% okay. 3/21 subtests failed, 85.71% okay. make: *** [test_dynamic] Error 29
----- Original Message ----- From: "Jochen Wiedmann" <jo...@ispsoft.de> To: "Leif W" <warp...@usa.net> Cc: <pe...@lists.mysql.com> Sent: Sunday, August 10, 2003 5:44 AM Subject: Re: DBD::mysql t/dbdadmin test failure 7, 11, 15
Quoting Leif W <warp...@usa.net>:
t/dbdadmin.........NOK 7New DB not in DSN list t/dbdadmin.........NOK 11DSN testab not in DSN list. t/dbdadmin.........NOK 15DSN testac not in DSN list. t/dbdadmin.........FAILED tests 7, 11, 15 Failed 3/21 tests, 85.71% okay
We'd be thankful, if you could debug these problems within the test script. These tests typically generate a list of databases and expect to find some database in the list. The most possible reason is with case sensitivity/insensitivity. It would help to know how the returned lists look like.
It may be possible that a simple
make test TEST_FILES=t/dbdadmin.t TEST_VERBOSE=1
gives an answer. Otherwise you might be able to win this info using the Perl debugger:
make testdb TEST_FILE=t/dbdadmin.t
P.S. note that --testport gives an error:
perl
Makefile.PL --testuser=root --testpassword=passwd --testhost=localhost --tes
tport=3306
Try --testhost=localhost:3306
Jochen




