barbie / test-xhtml

Test your web page DTD validation

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

cannot install due to failing tests

kfwebmaster opened this issue · comments

cannot install due to failing test.

might be related to change in API for XML::LibXML: https://metacpan.org/release/SHLOMIF/XML-LibXML-2.0202/source/Changes#L4-5

this is the output for make test

> make test
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/01use.t ......... ok   
t/10filetests.t ... ok     
t/11filetests.t ... ok   
t/20xmlstrings.t .. 3/4 
#   Failed test 'XHTML validity check for XML string - No PASS'
#   at t/20xmlstrings.t line 28.
#          got: '1'
#     expected: '0'

#   Failed test 'XHTML validity check for XML string - FAIL'
#   at t/20xmlstrings.t line 29.
#          got: '0'
#     expected: '1'
# Looks like you failed 2 tests of 4.
t/20xmlstrings.t .. Dubious, test returned 2 (wstat 512, 0x200)
Failed 2/4 subtests 
t/90podtest.t ..... skipped: Author tests not required for installation
t/91podcover.t .... skipped: Author tests not required for installation
t/94metatest.t .... skipped: Author tests not required for installation
t/95changedate.t .. skipped: Author tests not required for installation
t/96metatest.t .... skipped: Author tests not required for installation

Test Summary Report
-------------------
t/20xmlstrings.t (Wstat: 512 Tests: 4 Failed: 2)
  Failed tests:  3-4
  Non-zero exit status: 2
Files=9, Tests=20,  5 wallclock secs ( 0.02 usr  0.01 sys +  0.55 cusr  0.15 csys =  0.73 CPU)
Result: FAIL
Failed 1/9 test programs. 2/20 subtests failed.
make: *** [test_dynamic] Error 255

changed line lib/Test/XHTML/Valid.pm:83

-my $parser = XML::LibXML->new;
+my $parser = XML::LibXML->new(load_ext_dtd => 1);

and now it seems to work:

> make test
Skip blib/lib/Test/XHTML.pm (unchanged)
Skip blib/lib/Test/XHTML/WAI.pm (unchanged)
cp lib/Test/XHTML/Valid.pm blib/lib/Test/XHTML/Valid.pm
Skip blib/lib/Test/XHTML/Critic.pm (unchanged)
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/01use.t ......... ok   
t/10filetests.t ... ok     
t/11filetests.t ... ok   
t/20xmlstrings.t .. ok   
t/90podtest.t ..... skipped: Author tests not required for installation
t/91podcover.t .... skipped: Author tests not required for installation
t/94metatest.t .... skipped: Author tests not required for installation
t/95changedate.t .. skipped: Author tests not required for installation
t/96metatest.t .... skipped: Author tests not required for installation
All tests successful.
Files=9, Tests=20,  5 wallclock secs ( 0.02 usr  0.01 sys +  0.57 cusr  0.15 csys =  0.75 CPU)
Result: PASS

PR incoming.