GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
Test2::Harness::Runner::DepTracer(3) User Contributed Perl Documentation Test2::Harness::Runner::DepTracer(3)

Test2::Harness::Runner::DepTracer - Tool for tracing module dependencies as they are loaded.

This tool is used by Test2::Harness to build a graph of dependancies which can then be used to blacklist modified modules (and anything thatuses them) when they change under a preloaded runner.

    use Test2::Harness::Runner::DepTracer;

    my $dt = Test2::Harness::Runner::DepTracer->new();

    $dt->start();

    require Some::Thing;

    # You can always check for and retrieve an active DepTrace this way:
    my $dt_reference = Test2::Harness::Runner::DepTracer->ACTIVE;

    $dt->stop();

    my $dep_map = $dt->dep_map;

    my $loaded_by = $dep_map->{'Some/Thing.pm'};
    print "Some::Thing was directly or indirectly loaded by:\n" . join("\n" => @$loaded_by) . "\n";

These can be specified at construction, and will be populated during use.
$hashref = $dt->exclude
A hashref of files/modules to exclude from dep tracking. By default "strict" and "warnings" are excluded.
$hashref = $dt->dep_map
Every file which is loaded while the tool is started will have an entry in this hash, each value is an array of all files which loaded the key file directly or indirectly.
$hashref = $dt->loaded
How many times each file was directly loaded.

$dt->start
Start tracking modules which are loaded.
$dt->stop
Stop tracking moduels that are loaded.

$dt_or_undef = Test2::Harness::Runner::DepTracer->ACTIVE();
Get the currently active DepTracer, if any.

The source code repository for Test2-Harness can be found at http://github.com/Test-More/Test2-Harness/.

Chad Granum <exodist@cpan.org>

Chad Granum <exodist@cpan.org>

Copyright 2020 Chad Granum <exodist7@gmail.com>.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

See http://dev.perl.org/licenses/

2022-03-23 perl v5.32.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.