.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.43) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "Test::Kwalitee 3pm" .TH Test::Kwalitee 3pm "2022-12-06" "perl v5.36.0" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Test::Kwalitee \- Test the Kwalitee of a distribution before you release it .SH "VERSION" .IX Header "VERSION" version 1.28 .SH "SYNOPSIS" .IX Header "SYNOPSIS" In a separate test file: .PP .Vb 7 \& use Test::More; \& use strict; \& use warnings; \& BEGIN { \& plan skip_all => \*(Aqthese tests are for release candidate testing\*(Aq \& unless $ENV{RELEASE_TESTING}; \& } \& \& use Test::Kwalitee \*(Aqkwalitee_ok\*(Aq; \& kwalitee_ok(); \& done_testing; .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" Kwalitee is an automatically-measurable gauge of how good your software is. That's very different from quality, which a computer really can't measure in a general sense. (If you can, you've solved a hard problem in computer science.) .PP In the world of the \s-1CPAN,\s0 the \s-1CPANTS\s0 project (\s-1CPAN\s0 Testing Service; also a funny acronym on its own) measures Kwalitee with several metrics. If you plan to release a distribution to the \s-1CPAN\s0 \*(-- or even within your own organization \&\*(-- testing its Kwalitee before creating a release can help you improve your quality as well. .PP \&\f(CW\*(C`Test::Kwalitee\*(C'\fR and a short test file will do this for you automatically. .SH "USAGE" .IX Header "USAGE" Create a test file as shown in the synopsis. Run it. It will run all of the potential Kwalitee tests on the current distribution, if possible. If any fail, it will report those as regular diagnostics. .PP If you ship this test, it will not run for anyone else, because of the \&\f(CW\*(C`RELEASE_TESTING\*(C'\fR guard. (You can omit this guard if you move the test to xt/release/, which is not run automatically by other users.) .SH "FUNCTIONS" .IX Header "FUNCTIONS" .SS "kwalitee_ok" .IX Subsection "kwalitee_ok" With no arguments, runs all standard metrics. .PP To run only a handful of tests, pass their name(s) to the \f(CW\*(C`kwalitee_ok\*(C'\fR function: .PP .Vb 1 \& kwalitee_ok(qw( use_strict has_tests )); .Ve .PP To disable a test, pass its name with a leading minus (\f(CW\*(C`\-\*(C'\fR): .PP .Vb 1 \& kwalitee_ok(qw( \-use_strict has_readme )); .Ve .SH "BACK-COMPATIBILITY MODE" .IX Header "BACK-COMPATIBILITY MODE" Previous versions of this module ran tests directly via the \f(CW\*(C`import\*(C'\fR sub, like so: .PP .Vb 2 \& use Test::Kwalitee; \& # and that\*(Aqs it! .Ve .PP \&...but this is problematic if you need to perform some setup first, as you would need to do that in a \f(CW\*(C`BEGIN\*(C'\fR block, or manually call \f(CW\*(C`import\*(C'\fR. This is messy! .PP However, this calling path is still available, e.g.: .PP .Vb 1 \& use Test::Kwalitee tests => [ qw( use_strict has_tests ) ]; .Ve .SH "METRICS" .IX Header "METRICS" The list of each available metric currently available on your system can be obtained with the \f(CW\*(C`kwalitee\-metrics\*(C'\fR command (with descriptions, if you pass \f(CW\*(C`\-\-verbose\*(C'\fR or \f(CW\*(C`\-v\*(C'\fR, but as of Module::CPANTS::Analyse 0.97_03, the tests include: .IP "\(bu" 4 has_abstract_in_pod .Sp Does the main module have a \f(CW\*(C`=head1 NAME\*(C'\fR section with a short description of the distribution? .IP "\(bu" 4 has_buildtool .Sp Does the distribution have a build tool file? .IP "\(bu" 4 has_changelog .Sp Does the distribution have a changelog? .IP "\(bu" 4 has_humanreadable_license .Sp Is there a \f(CW\*(C`LICENSE\*(C'\fR section in documentation, and/or a \fI\s-1LICENSE\s0\fR file present? .IP "\(bu" 4 has_license_in_source_file .Sp Is there license information in any of the source files? .IP "\(bu" 4 has_manifest .Sp Does the distribution have a \fI\s-1MANIFEST\s0\fR? .IP "\(bu" 4 has_meta_yml .Sp Does the distribution have a \fI\s-1META\s0.yml\fR file? .IP "\(bu" 4 has_readme .Sp Does the distribution have a \fI\s-1README\s0\fR file? .IP "\(bu" 4 has_tests .Sp Does the distribution have tests? .IP "\(bu" 4 manifest_matches_dist .Sp Do the \fI\s-1MANIFEST\s0\fR and distribution contents match? .IP "\(bu" 4 meta_json_conforms_to_known_spec .Sp Does \s-1META\s0.json conform to the recognised \s-1META\s0.json specification? (For specs see CPAN::Meta::Spec) .IP "\(bu" 4 meta_json_is_parsable .Sp Can the \fI\s-1META\s0.json\fR be parsed? .IP "\(bu" 4 meta_yml_conforms_to_known_spec .Sp Does \s-1META\s0.yml conform to any recognised \s-1META\s0.yml specification? (For specs see ) .IP "\(bu" 4 meta_yml_is_parsable .Sp Can the \fI\s-1META\s0.yml\fR be parsed? .IP "\(bu" 4 no_broken_auto_install .Sp Is the distribution using an old version of Module::Install? Versions of Module::Install prior to 0.89 do not detect correctly that \f(CW\*(C`CPAN\*(C'\fR/\f(CW\*(C`CPANPLUS\*(C'\fR shell is used. .IP "\(bu" 4 no_broken_module_install .Sp Does the distribution use an obsolete version of Module::Install? Versions of Module::Install prior to 0.61 might not work on some systems at all. Additionally if the \fIMakefile.PL\fR uses the \f(CW\*(C`auto_install()\*(C'\fR feature, you need at least version 0.64. Also, 1.04 is known to be broken. .IP "\(bu" 4 no_symlinks .Sp Does the distribution have no symlinks? .IP "\(bu" 4 use_strict .Sp Does the distribution files all use strict? .SH "ACKNOWLEDGEMENTS" .IX Header "ACKNOWLEDGEMENTS" With thanks to \s-1CPANTS\s0 and Thomas Klausner, as well as test tester Chris Dolan. .SH "SEE ALSO" .IX Header "SEE ALSO" .IP "\(bu" 4 kwalitee-metrics (in this distribution) .IP "\(bu" 4 Module::CPANTS::Analyse .IP "\(bu" 4 App::CPANTS::Lint .IP "\(bu" 4 Test::Kwalitee::Extra .IP "\(bu" 4 Dist::Zilla::Plugin::Test::Kwalitee .IP "\(bu" 4 Dist::Zilla::Plugin::Test::Kwalitee::Extra .IP "\(bu" 4 Dist::Zilla::App::Command::kwalitee .SH "SUPPORT" .IX Header "SUPPORT" Bugs may be submitted through the \s-1RT\s0 bug tracker (or bug\-Test\-Kwalitee@rt.cpan.org ). .PP There is also a mailing list available for users of this distribution, at . .PP There is also an irc channel available for users of this distribution, at \&\f(CW\*(C`#perl\*(C'\fR on \f(CW\*(C`irc.perl.org\*(C'\fR . .SH "AUTHORS" .IX Header "AUTHORS" .IP "\(bu" 4 chromatic .IP "\(bu" 4 Karen Etheridge .SH "CONTRIBUTORS" .IX Header "CONTRIBUTORS" .IP "\(bu" 4 David Steinbrunner .IP "\(bu" 4 Gavin Sherlock .IP "\(bu" 4 Kenichi Ishigaki .IP "\(bu" 4 Nathan Haigh .IP "\(bu" 4 Zoffix Znet .IP "\(bu" 4 Daniel Perrett .SH "COPYRIGHT AND LICENSE" .IX Header "COPYRIGHT AND LICENSE" This software is copyright (c) 2005 by chromatic. .PP This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.