Punk
view release on metacpan or search on metacpan
t/1200-config.t view on Meta::CPAN
# looked secret-shaped warned, and `secrets => 'strict'` refused to boot. It
# is gone. Whether a password sits in the file is the decision of whoever
# writes the file, and a warning that fires on a key's name rather than on
# anything it knows is a warning people learn to ignore.
#
# These assert the silence, so reintroducing it fails here rather than in
# somebody's boot log.
{
unlink "$dir/punk.local.yml" if -e "$dir/punk.local.yml";
for my $key (qw(password passwd secret token api_key private_key
credentials auth)) {
write_file('punk.yml', "thing:\n $key: something\n");
my @warned;
{
local $SIG{__WARN__} = sub { push @warned, $_[0] };
Punk::Config->load(file => "$dir/punk.yml", env => 'none');
}
is(scalar @warned, 0, "a plaintext '$key' is loaded without comment");
}
( run in 2.988 seconds using v1.01-cache-2.11-cpan-036bef1c656 )