Config-General-Hierarchical
view release on metacpan or search on metacpan
}
},
"runtime" : {
"requires" : {
"Carp" : 0,
"Class::Accessor::Fast" : 0,
"Clone::PP" : "1.02",
"Config::General" : "2.49",
"Cwd" : 0,
"Scalar::Util" : "1.18",
"Test::Differences" : "0.47"
}
}
},
"release_status" : "stable",
"version" : "0.07"
}
directory:
- t
- inc
requires:
Carp: 0
Class::Accessor::Fast: 0
Clone::PP: 1.02
Config::General: 2.49
Cwd: 0
Scalar::Util: 1.18
Test::Differences: 0.47
version: 0.07
Makefile.PL view on Meta::CPAN
WriteMakefile(
NAME => 'Config::General::Hierarchical',
PREREQ_PM => {
'Carp' => 0,
'Class::Accessor::Fast' => 0,
'Clone::PP' => 1.02,
'Config::General' => 2.49,
'Cwd' => 0,
'Scalar::Util' => 1.18,
'Test::Differences' => 0.47,
},
VERSION_FROM => 'lib/Config/General/Hierarchical.pm',
clean => {
FILES =>
'*~ .*~ */*~ */.*~ nohup.out *.tdy t/*.tdy Hierarchical/*.tdy t/dir/*~ t/dump.conf t/import.conf t/dir cover_db'
}
);
package MY;
# testscript for Config::General::Hierarchical module
#
# needs to be invoked using the command "make test" from
# the Config::General::Hierarchical source directory.
#
# under normal circumstances every test should succeed.
use Config::General::Hierarchical;
use Test::More tests => 35;
use Test::Differences;
my $cfg = Config::General::Hierarchical->new( file => 't/get.conf' );
is( $cfg->get('a'), 'b', 'get call' );
is( $cfg->_a, 'b', 'AUTOLOAD call' );
isa_ok( $cfg->_e, 'Config::General::Hierarchical', 'AUTOLOAD call (no cache)' );
eval { $cfg->unknown };
like(
$@,
qr{Can't locate object method "unknown" via package "Config::General::Hierarchical" at t/03_get.t line \d+.\n},
t/04_constraint.t view on Meta::CPAN
# testscript for Config::General::Hierarchical module
#
# needs to be invoked using the command "make test" from
# the Config::General::Hierarchical source directory.
#
# under normal circumstances every test should succeed.
use Config::General::Hierarchical;
use Test::More tests => 73;
use Test::Differences;
my $cfg = TestConfig->new( file => 't/constraint.conf' );
isa_ok( $cfg, 'Config::General::Hierarchical', 'class inheritance' );
eval { TestConfig->import };
is( $@, '', 'syntax' );
eval { TestConfig3->import };
is( $@, "TestConfig3: syntax method musts return an HASH reference\n",
'wrong syntax' );
t/99_dump.t view on Meta::CPAN
# under normal circumstances every test should succeed.
my $tests;
my $skip;
BEGIN {
$tests = 59;
}
use Test::More tests => $tests;
use Test::Differences;
require_ok Config::General::Hierarchical::Dump;
require_ok Config::General::Hierarchical::DumpTest;
`echo "#!$^X -MConfig::General::Hierarchical::Dump\nvariable value\n<node>\n key value\n keys\n</node>\ndefined" > t/dump.conf`;
`chmod 755 t/dump.conf`;
is( `t/dump.conf`, <<EOF, 'self execution' );
defined = '';
node->key = 'value';
( run in 1.859 second using v1.01-cache-2.11-cpan-39bf76dae61 )