The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Test::CodeGen::Protection - Test functions for generated files

VERSION

version 0.06

is_protected_document_ok($format, $code, $message)

    is_protected_document_ok 'Perl', $string, $message;

This test will pass if $string is a document that matches the following conditions:

  • Has start and end CodeGen::Protection markers

  • The start and end checksums match

  • The text within the start and end markers matches the checksums

is_protected_file_ok($format, $filename, $message)

    is_protected_file_ok 'HTML', $filename, $message;

Like is_protected_document_ok, but accepts a filename. Will fail under the same conditions.

AUTHOR

Curtis "Ovid" Poe <ovid@allaroundtheworld.fr>

COPYRIGHT AND LICENSE

This software is copyright (c) 2021 by Curtis "Ovid" Poe.

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