Subject: | Tests 'Movie Language', 'Movie Country', and 'Movies IMDB Code' failed |
IMDB-Film-0.46
This is perl, v5.10.1 (*) built for i486-linux-gnu-thread-multi
Linux luffy 2.6.32-24-generic #43-Ubuntu SMP Thu Sep 16 14:17:33 UTC
2010 i686 GNU/Linux
While running 'install IMDB::Film' from the CPAN shell:
Running make test
PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e"
"test_harness(0, 'blib/lib', 'blib/arch')" t/01_base.t
t/m1_get_movie_by_code.t t/m2_get_movie_by_title.t
t/m3_get_movie_by_wrong_title.t t/m4_get_movie_by_title_single_match.t
t/m5_get_movie_by_title_without_rate.t
t/m6_get_movie_by_title_with_cr_casts.t t/m7_get_movie_by_info_offline.t
t/01_base.t .............................. ok
t/m1_get_movie_by_code.t ................. 1/22
# Failed test 'Movie Language'
# at t/m1_get_movie_by_code.t line 57.
# got: undef
# expected: 'English'
# Failed test 'Movie Country'
# at t/m1_get_movie_by_code.t line 58.
# got: undef
# expected: 'USA'
t/m1_get_movie_by_code.t ................. 12/22 # Looks like you failed
2 tests of 22.
t/m1_get_movie_by_code.t ................. Dubious, test returned 2
(wstat 512, 0x200)
Failed 2/22 subtests
t/m2_get_movie_by_title.t ................ 1/18
# Failed test 'Movie Language'
# at t/m2_get_movie_by_title.t line 59.
# got: undef
# expected: 'English'
# Failed test 'Movie Country'
# at t/m2_get_movie_by_title.t line 60.
# got: undef
# expected: 'USA'
t/m2_get_movie_by_title.t ................ 12/18 # Looks like you failed
2 tests of 18.
t/m2_get_movie_by_title.t ................ Dubious, test returned 2
(wstat 512, 0x200)
Failed 2/18 subtests
t/m3_get_movie_by_wrong_title.t .......... ok
t/m4_get_movie_by_title_single_match.t ... ok
t/m5_get_movie_by_title_without_rate.t ... 1/2
# Failed test 'Movies IMDB Code'
# at t/m5_get_movie_by_title_without_rate.t line 11.
# got: '0061175'
# expected: '0412158'
# Looks like you failed 1 test of 2.
t/m5_get_movie_by_title_without_rate.t ... Dubious, test returned 1
(wstat 256, 0x100)
Failed 1/2 subtests
t/m6_get_movie_by_title_with_cr_casts.t .. ok
t/m7_get_movie_by_info_offline.t ......... ok
Test Summary Report
-------------------
t/m1_get_movie_by_code.t (Wstat: 512 Tests: 22 Failed: 2)
Failed tests: 9-10
Non-zero exit status: 2
t/m2_get_movie_by_title.t (Wstat: 512 Tests: 18 Failed: 2)
Failed tests: 9-10
Non-zero exit status: 2
t/m5_get_movie_by_title_without_rate.t (Wstat: 256 Tests: 2 Failed: 1)
Failed test: 1
Non-zero exit status: 1
Files=8, Tests=54, 21 wallclock secs ( 0.05 usr 0.01 sys + 2.70 cusr
0.16 csys = 2.92 CPU)
Result: FAIL
Failed 3/8 test programs. 5/54 subtests failed.
make: *** [test_dynamic] Error 255
STEPANOV/IMDB-Film-0.46.tar.gz
/usr/bin/make test -- NOT OK
A patch that presumably fixes 'language' and 'country' issues is attached.
Subject: | Film.pm.patch |
--- Film.pm 2010-09-08 21:34:15.000000000 +0700
+++ Film.pm.new 2010-10-01 05:46:38.000000000 +0700
@@ -1057,7 +1057,7 @@
my (@countries);
while(my $tag = $parser->get_tag()) {
- if( $tag->[0] eq 'a' && $tag->[1]{href} && $tag->[1]{href} =~ /countries/i ) {
+ if( $tag->[0] eq 'a' && $tag->[1]{href} && $tag->[1]{href} =~ /country/i ) {
my $text = $parser->get_text();
$text =~ s/\n//g;
push @countries, $text;
@@ -1093,7 +1093,7 @@
while($tag = $parser->get_tag()) {
- if( $tag->[0] eq 'a' && $tag->[1]{href} && $tag->[1]{href} =~ /languages/i ) {
+ if( $tag->[0] eq 'a' && $tag->[1]{href} && $tag->[1]{href} =~ /language/i ) {
my $text = $parser->get_text();
$text =~ s/\n//g;
push @languages, $text;