#!perl

use strict;
use warnings;
use Test::More;   # needed to provide plan.

plan skip_all => "These tests are for authors only!" unless $ENV{AUTHOR_TESTING} or $ENV{RELEASE_TESTING};

# META.yml is generated by `make dist`, not by `perl Makefile.PL`.
# Only run kwalitee against an unpacked tarball (e.g. `make disttest`),
# not against the bare source tree.
plan skip_all => "META.yml not present (run under `make disttest`, not from the source tree)"
    if !-f 'META.yml';

eval { require Test::Kwalitee };
plan skip_all => "Test::Kwalitee required for testing kwalitee: $@" if $@;

eval "use Test::Kwalitee";
