Test2:...Runner(3pm)

πŸ’– Test2::Harness::Runner β€” the Runner(3pm) page, bestie edition πŸ’–

So this is the manual for Test2::Harness::Runner, from the User Contributed Perl Documentation set. It's the base class for test runners. Yep, the parent of all the little runner classes. The blueprint. The blueprint that runs your whole test suite. iconic behavior honestly.


✨ NAME ✨

Test2::Harness::Runner β€” base class for test runners. she's the mother of runners πŸ’…


🌸 DESCRIPTION 🌸

Okay so real talk: this module does the heavy lifting of running all the tests. Like, all of it. The whole gym session. She's in the back doing the work while everyone else gets the credit. main character energy but make it infrastructure.

You should never need to create an instance of the runner yourself. Not your job, not your moment. In most cases the runner module is exposed via a callback or a plugin affordance β€” so it'll come find you when it wants to hang out 🫢


πŸ‘‘ PUBLIC METHODS πŸ‘‘

πŸŽ€ FROM SETTINGS πŸŽ€

These are attributes with values set from the Test2::Harness::Settings instance created from command line arguments. (Yes, the original says "attributesd". We're leaving that typo exactly where it is. It's part of the lore now. fr fr.)

For the most up to date documentation on these, go look at App::Yath::Options::Runner. She's the source of truth bestie, not me.
  • $runner->includes
  • $runner->tlib
  • $runner->lib
  • $runner->blib
  • $runner->unsafe_inc
  • $runner->use_fork
  • $runner->preloads
  • $runner->preload_threshold
  • $runner->switches
  • $runner->cover
  • $runner->event_timeout
  • $runner->post_exit_timeout

πŸ¦‹ FROM CONSTRUCTION πŸ¦‹

These attributes get set when the runner is created. Like, born-with-it attributes. congenital slay.

  • $path = $runner->dir β€” path to the working directory. Where the vibes happen πŸ“
  • $settings = $runner->settings β€” the App::Yath::Settings instance. her settings, her rules ✨
  • $coderef = $runner->fork_job_callback β€” callback used to spawn new tests via fork. fork fork fork πŸ’…
  • $coderef = $runner->respawn_runner_callback β€” callback to restart the runner process. you can't keep her down, she respawns 🧚
  • $bool = $runner->monitor_preloads β€” true if preloads should be watched for changes. πŸ‘€ watching, always watching
  • $int = $runner->jobs_todo β€” a count of total jobs to run. This will always be 0 in a persistent runner. zero. nada. don't @ me. πŸ”₯

🌈 OTHER PUBLIC METHODS 🌈

heads up bestie: If a method is not documented here then it is an implementation detail and you should not use it. not. documented. do not touch. it's giving private, it's giving stay out of my room 😭
  • $class = $runner->job_class β€” class for new test jobs.
  • $preload = $runner->preloader β€” get the Test2::Harness::Runner::Preloader instance.
  • $state = $runner->state β€” get the Test2::Harness::Runner::State instance.
  • @list = $runner->all_libs β€” get all the libs that should be added to @INC by default. Note that specific runs and even specific tests can have custom paths on top of these. so this is the baseline, the default fit, and then individual runs accessorize πŸ’œ

πŸ”₯ SOURCE πŸ”₯

The source code repository for Test2-Harness can be found at http://github.com/Test-More/Test2-Harness/. go star it, go lurk, go read the code 🫢


πŸŽ€ MAINTAINERS πŸŽ€

Chad Granum <exodist@cpan.org>


⭐ AUTHORS ⭐

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/


okay that's the whole page, no cap, every single line accounted for 🌸 this was documented by the fine folks on perl v5.40.1, and the date on this one is 2026-05-10 β€” and yes, from the original it's still filed under Test2:...Runner(3pm) because the ellipsis is doing its own thing and we respect her journey πŸ’…πŸ’–

πŸ“¦ where this page comes from