./devel/p5-Test-Trap, Perl extension to trap exit codes, exceptions, output

[ CVSweb ] [ Homepage ] [ RSS ] [ Required by ] [ Add to tracker ]


Branch: CURRENT, Version: 0.3.2, Package name: p5-Test-Trap-0.3.2, Maintainer: pkgsrc-users

This modules is primarily (but not exclusively) for use in test
scripts: A block eval on steroids, configurable and extensible,
but by default trapping (Perl) STDOUT, STDERR, warnings, exceptions,
would-be exit codes, and return values from boxed blocks of test
code.

The values collected by the latest trap can then be queried or
tested through a special trap object.


Required to run:
[lang/perl5] [devel/p5-Data-Dump] [devel/p5-Test-Simple]

Master sites: (Expand)

SHA1: 92dfe5c1437375d17e21ac710eea26588ebc2d61
RMD160: e160871f406e1cee6152c8237cb236f8b5caa3dd
Filesize: 53.614 KB

Version history: (Expand)


CVS history: (Expand)


   2015-04-17 03:37:46 by Makoto Fujiwara | Files touched by this commit (2) | Package updated
Log message:
(pkgsrc)
 - Convert DEPENDS from p5-Test-Tester to p5-Test-Simple > 1.001010
   (See commit log on devel/p5-Test-Simle)
(upstream)
 - Update 0.3.0 to 0.3.2
---------------------
0.3.2   Tue Feb 24 00:19:23 CET 2015
        The tempfile-preserve strategy was (always) broken on
        non-perlio perls.
        Also, some of the tests were (recently) noisy on old perls.
        Test::Trap::Builder::TempFile:
        - add a GOTPERLIO guard to each IO_LAYERS block.
        Tests:
        - 03-files.pl now avoid "used only once" warnings.

0.3.1   Mon Feb 23 21:43:30 CET 2015
        This release doesn't touch library code, but addresses some
        test issues:
        - It fixes RT #102271 by checking for the presence of a
          utf8-layer on the original STDOUT, instead of assuming its
          absence.
        - It makes some test code cleaner.
        - It silences redefine warnings during testing on certain
          platforms.
        Library files: No change but version bump.
        Tests:
        - 03-files* now use another global to specify the class to
          require, replacing a quick-and-dirty hack that turned out to
          be noisy on some platforms, including Cygwin.
        - {15-tempfile,16-systemsafe}-options.t now check for the
          presence of utf8-layer on STDOUT, instead of assuming its
          absence.  (Either of the environment variables PERL_UNICODE
          and PERL5OPT could cause such a layer to be present, and
          there might be other ways to do it.)
   2015-02-17 14:20:28 by Makoto Fujiwara | Files touched by this commit (2) | Package updated
Log message:
Update 0.2.5 to 0.3.0
---------------------
(From the Changes)
0.3.0   Thu Dec 18 21:57:51 CET 2014
        This release, in brief:
        - improves clarity through nomenclature:
              * renames "(output layer) backend implementation" to
                "(capture) strategy", for more standard nomenclature
                (and less of a mouthful);
              * renames "pseudo-layer" to "multi-layer" (if so
                declared) or "non-trapping layer" (neither is a direct
                analogue to PerlIO pseudo layers, so the nomenclature
                was misleading);
        - adds (import) options to the TempFile and SystemSafe capture
          strategy factories, allowing for different ways to handle
          PerlIO layers;
        - using these for two new standard capture strategies,
          "tempfile-preserve" and "systemsafe-preserve"; and
        - fixes a bug in SystemSafe.
   2014-11-23 15:31:51 by Amitai Schlair | Files touched by this commit (2) | Package updated
Log message:
Update to 0.2.5. From the changelog:

This release localizes $! (ERRNO) for internal operations that
change it, as suggested by Felipe Gasper. For the same operations,
it also localizes $^E (extended OS error).

Library files:
- Localize $! and $^E for internal operations that change them.
Tests:
- Check that bare test blocks leave $!, %!, and $^E unchanged,
  but that blocks that modify $! and $^E still do so.
Also:
- Added Module::Build to the configure_requires.
- Fix emacs mode line on t/14-leaks.t.
- Better comments in lib/Test/Trap/Builder.pm.
   2014-06-09 21:07:04 by Amitai Schlair | Files touched by this commit (2) | Package updated
Log message:
Update to 0.2.4. From the changelog:

This release fixes a memory leak with the default tempfile backend
layer implementation for trapping output. The systemsafe alternative
backend had the same kind of leak, and has also been fixed. (The
perlio alternative backend was not affected.) Thanks go again to
Felipe Gasper for discovering this!

Test::Trap::Builder:
- Add a method ExceptionFunction to make it easier to avoid
  circular references arising from registered closures.
  Document and export this method.
Test::Trap::Builder::TempFile:
- Break a circular reference chain.
Test::Trap::Builder::SystemSafe:
- Break a similar but slightly more complicated circular
  reference chain.
Tests:
- Added t/14-leaks.t to check that the reference count is as
  expected, at least with trivial code and standard setup for
  all three output layer backends.
- Regression test for the stale references.
Library files:
- RT #87263: typo fixes, courtesy dsteinbrunner@pobox.com.
- Localize the trap coderef, so that it does not hold on to
  what it closes over, creating stale references, but lets
  them go out of scope; thanks go to Felipe Gasper.
Documentation:
- Some clarification for RT #91687: Wrong exit code after die.
Also:
- Use ebhanssen@cpan.org for my email address.
- Update copyright years.
- Update MANIFEST.SKIP &c for use of git (goodbye subversion).
   2014-05-30 01:38:20 by Thomas Klausner | Files touched by this commit (3049)
Log message:
Bump for perl-5.20.0.
Do it for all packages that
* mention perl, or
* have a directory name starting with p5-*, or
* depend on a package starting with p5-
like last time, for 5.18, where this didn't lead to complaints.
Let me know if you have any this time.
   2013-05-31 14:42:58 by Thomas Klausner | Files touched by this commit (2880)
Log message:
Bump all packages for perl-5.18, that
a) refer 'perl' in their Makefile, or
b) have a directory name of p5-*, or
c) have any dependency on any p5-* package

Like last time, where this caused no complaints.
   2013-01-19 23:57:06 by Amitai Schlair | Files touched by this commit (2) | Package updated
Log message:
Update to 0.2.2. From the changelog:

Test::Trap::Builder::TempFile & Test::Trap::Builder::SystemSafe:
- RT #61776: Remove temporary files at first opportunity;
  thanks go to Ian Goodacre.
Documentation:
- RT #61773: return from trap function
  Document what trap { ... } returns.
Tests:
- RT #75430: Failing tests in 06-layer.t
  Convert a number of die_is to die_like, handling cases with
  and without trailing comma from carp.
- Unset another taint-checked environment variable, CDPATH;
  thanks go to CPAN testers.
   2012-10-31 12:19:55 by Aleksej Saushev | Files touched by this commit (1460)
Log message:
Drop superfluous PKG_DESTDIR_SUPPORT, "user-destdir" is default these days.