Perl-Toolchain-Gang / Module-Metadata

Gather package and POD information from perl module files
http://metacpan.org/release/Module-Metadata/
Other
8 stars 16 forks source link

package_versions_from_directory needs test for conflict checking #23

Open wchristian opened 7 years ago

wchristian commented 7 years ago

I don't have the time to make a test for this right now, thus i am documenting here what needs to be done:

In t/metadata.t the tests for package_versions_from_directory need to be extended by way of adding another file to the dist being inspected, said file needing to be stuck in a sub dir, e.g. Nested::Simple. The file should contain code sufficient to trigger the error of "Unexpected conflict in '$package'; multiple versions found.\n". Said throwing should be considered a success.

This needs to be tested because in its current state the path splitting a little further up would keep this check from functioning properly. I am providing a fix for this in a pull request to come, but a test will need to be made as per above.