Test2::...::Error(3)

πŸ“¦ version 1.302214, in opensuse-leap 16.0

πŸ’– Test2::...::Error(3) πŸ’–

okay bestie, so this is a User Contributed Perl Documentation page (that's the manual name, iykyk ✨) and it's all about one tiny but iconic facet β€” Test2::EventFacet::Error.


✨ NAME ✨

Test2::EventFacet::Error β€” the facet for errors that need to be shown. literally its whole job πŸ’…

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so. when an event needs to convey errors, this is the facet that carries them. that's it, that's the vibe πŸŽ€

🌸 NOTES 🌸

heads up bestie, this facet lowkey has a little quirk:

  • it has the hash key 'errors'
  • and it's a list of facets, not a single item πŸ‘‘

so like, plural. multiple. a whole little squad of error facets. don't come for me, that's just how it is 🫢

πŸ’… FIELDS πŸ’…

okay these are the actual fields, and they each have a hash key AND a method accessor, because why choose πŸ€·β€β™€οΈ

  • $string = $error->{details}
  • $string = $error->details()

this is the explanation of the error, or the error itself (like, an exception, say). and here's the tea: in perl, exceptions may be blessed objects, so this field may contain a blessed object. so don't freak out if it's not a plain string, that's valid 🧚

  • $short_string = $error->{tag}
  • $short_string = $error->tag()

a short tag to categorize the error. it's usually 10 characters or less, and formatters may truncate longer tags β€” so keep it snappy, bestie βœ‚οΈ

  • $bool = $error->{fail}
  • $bool = $error->fail()

not all errors are fatal, okay?? some are displayed having already been handled. set this to true if you want the error to cause the test to fail. without this, the error is simply a diagnostics message that has no effect on the overall pass/fail result. so like, it's just vibes at that point, it doesn't actually weigh in on the score 🌈

πŸ”₯ SOURCE πŸ”₯

the source code repository for Test2 can be found at <https://github.com/Test-More/test-more/> β€” go check it out, the source is right there πŸ’œ

πŸ‘‘ MAINTAINERS πŸ‘‘

  • Chad Granum <exodist@cpan.org>

⭐ AUTHORS ⭐

  • Chad Granum <exodist@cpan.org>

(same person, they're carrying it fr fr 😭)

Copyright Chad Granum <exodist@cpan.org>.

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

See <https://dev.perl.org/licenses/>


and that's the whole page, bestie πŸ“ this lil gem was rendered by perl v5.42.0 on 2025-07-28, and the manual page itself is Test2::...::Error(3) β€” slay, go write some tests πŸ’–βœ¨πŸ¦‹

πŸ“¦ where this page comes from