++ed by:

1 PAUSE user

Kenichi Ishigaki


Test::PAUSE::Permissions - tests module permissions in your distribution


    # in your xt/perms.t

    use Test::PAUSE::Permissions;


This module is to test if modules in your distribution have proper permissions or not. You need to set RELEASE_TESTING to test this.

If your distribution has modules/packages that should not be indexed, you might want to generate META files before you run this test to provide no_index information to Test::PAUSE::Permissions.

You might also want to prepare .pause file to show who is releasing the distribution (you should have one to release distributions anyway).


This module exports only one function (yet):


Looks for packages with Parse::LocalDistribution, and tests if you have proper permissions for them by PAUSE::Permissions, which downloads 06perms.txt from CPAN before testing.

By default, all_permissions_ok looks into .pause file to find who is releasing the distribution.

You can also pass the author as an argument, though this is only useful when you generate this test every time you release a distribution.

    use Test::PAUSE::Permissions;
    # assumes ISHIGAKI is going to release the distribution

all_permissions_ok also looks into META files for <x_authority>, and each .pm file for $AUTHORITY variable, for your information.

You can pass an optional hash reference to all_permissions_ok() to change its behavior.

strict mode

    all_permissions_ok({strict => 1});

If this is set, all_permissions_ok would fail if the following conditions should be met:

the distribution is maintained by more than one person (or two people if x_authority is set).
the uploader has added a new indexable package.
and the distribution itself is not newly created.

In the case above, if the uploader uploads the distribution, permission to the new package is only given to the uploader (and the author specified in x_authority if applicable), and other maintainers will not be able to upload the distribution appropriately until they are given permission to the new package. Strict mode is to prevent such an (accidental) addtion so that everyone in a team can upload without a problem.

test also modules with a developer version

    all_permissions_ok({dev => 1});

This module ignores modules that won't be indexed (namely those that have a version number with an underscore in it) by default. If you do want to test them, set dev to true.


PAUSE::Permissions, App::PAUSE::CheckPerms


Kenichi Ishigaki, <ishigaki@cpan.org>


Copyright (C) 2014 by Kenichi Ishigaki.

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