ExtUti...iliary(3pm)

πŸ“¦
version 0.63 Β· 2 versions
  • 0.63 Β· debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking (latest)
  • 0.63 Β· ubuntu jammy
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

🌸 NAME 🌸

okay so bestie, welcome to ExtUtils::ModuleMaker::Auxiliary (that's the 3pm one, perl docs, you know the vibe) β€” it's a little grab-bag of subroutines for testing ExtUtils::ModuleMaker. no cap, that's the whole job description. πŸ’…


✨ DESCRIPTION ✨

so basically this package is holding a bunch of subroutines that get used in one or more of the t/*.t files in ExtUtils::ModuleMaker's test suite. πŸ§ͺ

and like β€” they might prove useful if you're out here writing test suites for distributions that subclass ExtUtils::ModuleMaker. it's giving "helper functions you didn't know you needed." 🫢


πŸŽ€ SUBROUTINES πŸŽ€

read_file_string()

  • Function: read the contents of a file into a string. yes, the whole thing, one string, slay. πŸ“–
  • Argument: a string holding the name of a file created by complete_build().
  • Returns: a string holding the text of the file read.
  • Used: to see whether the text of files such as README, Makefile.PL, etc. was created correctly β€” it hands you back a string that you can match a pattern against. iconic. ✨

read_file_array()

  • Function: read a file line-by-line into an array. one line per element, no notes. πŸ“š
  • Argument: a string holding the name of a file created by complete_build().
  • Returns: an array holding the lines of the file read.
  • Used: to see whether the text of files such as README, Makefile.PL, etc. was created correctly β€” it hands you back an array whose elements you can match patterns against. πŸ’–

five_file_tests()

  • Function: verify that the content of MANIFEST and lib/*.pm were created correctly.
  • Argument: two arguments, bestie, count 'em:
    1. A number predicting the number of entries in the MANIFEST.
    2. A reference to an array holding the components of the module's name, e.g.:
[ qw( Alpha Beta Gamma ) ]
  • Returns: n/a. nothing, nada, it just does the tests. πŸ™ˆ
  • Used: to see whether MANIFEST and lib/*.pm have correct text. it runs 6 Test::More tests:
    1. Number of entries in MANIFEST.
    2. Change to directory under lib.
    3. Applies read_file_string to the stem.pm file.
    4. Determine whether stem.pm's POD contains module name and abstract.
    5. Determine whether POD contains a HISTORY head.
    6. Determine whether POD contains correct author information.
six whole tests in one little subroutine. she's efficient, she's booked, she's busy. πŸ‘‘

check_MakefilePL()

  • Function: verify that the content of Makefile.PL was created correctly.
  • Argument: two arguments:
    1. A string holding the directory in which the Makefile.PL should have been created.
    2. A reference to an array holding strings, each of which is a prediction as to the content of particular lines in Makefile.PL.
  • Returns: n/a. again, nothing back, she's just checking. πŸ’€
  • Used: to see whether the Makefile.PL created by complete_build() has correct entries. it runs 1 Test::More test which checks NAME, VERSION_FROM, AUTHOR and ABSTRACT. all four, in one test, main character energy fr fr. πŸ”₯

🌈 SEE ALSO 🌈

  • ExtUtils::ModuleMaker.

okay that's the whole page, you're caught up, go write some tests bestie πŸ’– this lil doc is from perl v5.36.0, dated 2023-01-27 β€” User Contributed Perl Documentation, ExtUtils::ModuleMaker::Auxiliary(3pm). mwah, bye! πŸŽ€πŸ¦‹πŸ’…

πŸ“¦ where this page comes from