Branch: refs/heads/smoke-me/jkeenan/pod2html-single-tempdir-20210304
  Home:   https://github.com/Perl/perl5
  Commit: 910c86aeac5ace6579d5746d18a409d3b6e49638
      
https://github.com/Perl/perl5/commit/910c86aeac5ace6579d5746d18a409d3b6e49638
  Author: James E Keenan <[email protected]>
  Date:   2021-03-05 (Fri, 05 Mar 2021)

  Changed paths:
    M MANIFEST
    M cpan/Pod-Simple/lib/Pod/Simple.pm
    A ext/Pod-Html/corpus/perlpodspec-copy.pod
    A ext/Pod-Html/corpus/perlvar-copy.pod
    M ext/Pod-Html/t/crossref.t
    M ext/Pod-Html/t/crossref2.t
    M ext/Pod-Html/t/crossref3.t
    M ext/Pod-Html/t/feature.t
    M ext/Pod-Html/t/feature2.t
    M ext/Pod-Html/t/htmldir1.t
    M ext/Pod-Html/t/htmldir2.t
    M ext/Pod-Html/t/htmldir3.t
    M ext/Pod-Html/t/htmldir4.t
    M ext/Pod-Html/t/htmldir5.t
    M ext/Pod-Html/t/htmlescp.t
    M ext/Pod-Html/t/htmllink.t
    M ext/Pod-Html/t/htmlview.t
    A ext/Pod-Html/t/lib/Testing.pm
    R ext/Pod-Html/t/pod2html-lib.pl
    M ext/Pod-Html/t/poderr.t
    M ext/Pod-Html/t/podnoerr.t
    R ext/Pod-Html/testdir/perlpodspec-copy.pod
    R ext/Pod-Html/testdir/perlvar-copy.pod
    M t/porting/known_pod_issues.dat

  Log Message:
  -----------
  Replace older testing subroutines and library t/pod2html-lib.pl.

... and in turn introduce helper subs setup_testing_dir() and xconvert()
in t/lib/Testing.pm.

Once setup_testing_dir() is run, user will be in a tempdir --
specifically, in /sometempdir/ext/Pod-Html.  Any paths, current
directories, etc., which need to be calculated in order to be passed to
xconvert() will be calculated with respect to the latter directory.

In the BEGIN block we enable the user to run these tests either via the
harness ...

    cd t; ./perl harness ../ext/Pod-Html/t/*.t; cd -

... or individually from the top-level of the repository ...

    ./perl -Ilib ext/Pod-Html/t/htmldir2.t

Running from the top-level with the '-d' switch will facilitate use of
the Perl debugger.

Once we have run setup_testing_dir(), we read the "raw" expected HTML
from the DATA filehandle.  This gets task out of the way early;
previously it was buried deep within xconvert()'s predecessors.  It
means we can get rid of the 'tell' and 'seek' calls to re-read the DATA
handle.  In any given test file, we aim to get the same HTML output from
each different instance of xconvert().

Because we're inside a tempdir when running with these two subroutines,
we have to change back to our starting directory before the file ends so
that the tempdir 'CLEANUP => 1' functionality can clean up the tempdir.

Extra debugging output can be obtained by passing '1' or '2' as the
value of the 'debug' element for the hashref passed to xconvert().

We have now replaced all the testing routines found earlier in
t/pod2html-lib.pl, so that file can be deleted.

Silence complaints about POD formatting in dummy copy file.

These revisions take advantage of the fact that Pod-Html is
blead-upstream.  Hence, in one place where a specific version of
Pod::Simple was conditionally requested, we can eliminate the condition
because in blead it will always be met.

We do, however, need to have one change made upstream in Pod-Simple.

Various variable and directory names have been changed to be more
self-documenting.

There have as yet been no changes whatsoever in lib/Pod/Html.pm nor was
any of the expected HTML output in the DATA filehandles in t/*.t
changed.  So this testing rig should meet exactly the same conditions
as, say, Pod-Html in perl-5.32.


  Commit: d5cdcedb7150e41c1aa2e90722379c9db6016199
      
https://github.com/Perl/perl5/commit/d5cdcedb7150e41c1aa2e90722379c9db6016199
  Author: James E Keenan <[email protected]>
  Date:   2021-03-05 (Fri, 05 Mar 2021)

  Changed paths:
    M t/harness

  Log Message:
  -----------
  ext/Pod-Html/t/*.t tests can now be run in parallel

This module's tests no longer foul their own nest.  Each test file that
needs to create directories or files for testing now uses an indivdual
tempdir.  The assignment of ext/Pod-Html to "run in serial only" is no
longer needed.


Compare: https://github.com/Perl/perl5/compare/910c86aeac5a%5E...d5cdcedb7150

Reply via email to