Test::...Wrapper(3pm)

πŸ“¦
version 0.0306 Β· 2 versions
, in fedora 43

πŸ’– Test::...Wrapper(3pm) πŸ’–

okay bestie so the manual name is Test::...Wrapper(3pm) and it's part of the User Contributed Perl Documentation β€” and listen, this page is short but it's iconic, so let's get into it 🫢


✨ NAME ✨

Test::Run::Straps::EventWrapper β€” literally just a wrapper for a TAP::Parser::Result subclass that delegates to its methods and has its own methods. best of both worlds, no cap πŸ’…


🌸 DESCRIPTION 🌸

okay so here's the vibe. TAP::Parser's next() method returns a sub-class of TAP::Parser::Result. cute, right? but plot twist β€” we need to define our own methods on those objects. 😭

and the problem? we can't inherit from all the sub-classes. so instead we made this class, which:

  • holds an instance of the actual events πŸŽ€
  • delegates some methods to it πŸ¦‹
  • and defines some of its own methods ✨

it's giving "we couldn't have it all so we built it ourselves" and honestly? main character energy. πŸ‘‘


πŸ’« $event->is_pass() πŸ’«

returns whether the event can be considered a passed event. always returns a scalar boolean β€” no ambiguity, no drama, just a tidy little boolean bestie πŸ“


πŸ’« $self->get_next_test_number() πŸ’«

if this event is a test, then it returns the next expected test number. otherwise it returns undef. that's it. that's the whole method. 🧚


πŸ”₯ SEE ALSO πŸ”₯

  • Test::Run::Straps
  • Test::Run::Obj
  • Test::Run::Core

go read those too, iykyk πŸ’œ


πŸ“œ LICENSE πŸ“œ

this file is licensed under the MIT X11 License:

http://www.opensource.org/licenses/mit-license.php

πŸ‘‘ AUTHOR πŸ‘‘

Shlomi Fish, <http://www.shlomifish.org/>.


and that's the whole page bestie!! πŸ’– this was written by perl v5.42.0 and dated 2025-07-25, so if you're reading this from the future… hi, slay, and also, Test::...Wrapper(3pm) says hey. πŸŽ€βœ¨πŸ¦‹

πŸ“¦ where this page comes from